From 14eb79108494a2164695ad897a60a73e5fe48a66 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?JN=20Hern=C3=A1ndez?= Date: Tue, 14 May 2024 11:18:59 -0600 Subject: [PATCH] Add check server --- .github/workflows/ci.yml | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 20a479b..16f0449 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -40,10 +40,14 @@ jobs: ./scripts/server >/dev/null 2>&1 & echo "SERVER_PID=$!" >> "$GITHUB_ENV" - - name: Run test script + - name: Check server run: | - sleep 15 - curl localhost:8090/pong + if ps -p "${SERVER_PID}" > /dev/null; then + echo "Server script is running with PID: ${SERVER_PID}" + else + echo "Server script is not running." + exit 1 + fi - name: Stop server run: |