From 2075536a66557d86be0e230de16e840702fd69dd Mon Sep 17 00:00:00 2001 From: leehk Date: Thu, 17 Apr 2025 15:25:11 +0800 Subject: [PATCH] try --- .github/workflows/build.yml | 8 ++++---- .github/workflows/template_test.yml | 4 ++-- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index ce6a484..def3c2b 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -73,17 +73,17 @@ jobs: testContainerName: tests-aimingmedai # Pass test environment variables as JSON string testEnvs: > - '[ + [ "FRONTEND_URL=http://frontend:80", "BACKEND_URL=http://backend:80", "ENVIRONMENT=dev", "TESTING=1", - ]' + ] # Pass test directories as JSON string tests: > - '[ + [ "tests/integration/backend", - ]' + ] # Pass image definitions for compose setup as JSON string # Sensitive values should be passed via secrets and referenced within the template images: > diff --git a/.github/workflows/template_test.yml b/.github/workflows/template_test.yml index dd23217..c5cb4a8 100644 --- a/.github/workflows/template_test.yml +++ b/.github/workflows/template_test.yml @@ -146,8 +146,8 @@ jobs: - name: Run Tests shell: bash run: | - TEST_DIRS='["tests/integration/backend"]' - TEST_ENVS_JSON='["FRONTEND_URL=http://frontend:80","BACKEND_URL=http://backend:80","ENVIRONMENT=dev","TESTING=1"]' + TEST_DIRS='${ inputs.tests }' # JSON string of test directories/commands + TEST_ENVS_JSON='${ inputs.testEnvs }' # JSON string of environment variables RESULTS_PATH="${{ inputs.testResultsPath }}" STAGING_DIR="${{ runner.temp }}/test-results" # Use runner temp dir for results mkdir -p "$STAGING_DIR"