From 363e44a17e5ed2a838b5425dede9f0e8243abaf0 Mon Sep 17 00:00:00 2001 From: Matteo Mancini Date: Fri, 14 Feb 2025 16:41:04 +0100 Subject: [PATCH 1/9] QA-5882: defined an initial draft of the workflow --- .github/workflows/tracing.yaml | 127 +++++++++++++++++++++++++++++++++ 1 file changed, 127 insertions(+) create mode 100644 .github/workflows/tracing.yaml diff --git a/.github/workflows/tracing.yaml b/.github/workflows/tracing.yaml new file mode 100644 index 000000000..391108335 --- /dev/null +++ b/.github/workflows/tracing.yaml @@ -0,0 +1,127 @@ +name: Tracing Test + +on: + workflow_dispatch: + inputs: + environment: + description: 'Environment to run tests against' + required: true + type: environment + javaBranchName: + description: 'Provide the branch name for pn-b2b-client to clone' + required: false + default: main + type: string + + +defaults: + run: + shell: bash + +permissions: + id-token: write + contents: read + +env: + skip_checkUserMembership: "true" + skip_failNotSelectedEnvTagRef: "true" + SCRIPTS_FOLDER: "./scripts" + +jobs: + inputs: + runs-on: ubuntu-22.04 + environment: ${{ inputs.environment }} + + steps: + - name: Print Inputs + id: print_inputs + run: | + echo "- environment: \`${{ inputs.environment }}\`" >> $GITHUB_STEP_SUMMARY + echo "- normalized environment: \`${{ vars.NORM_ENV }}\`" >> $GITHUB_STEP_SUMMARY + echo "- ref: \`${{ github.ref }}\`" >> $GITHUB_STEP_SUMMARY + echo "- plat-dep versions: \`${{ vars.PLAT_DEP_VERSIONS_URL }}\`" >> $GITHUB_STEP_SUMMARY + echo "- kafkaPurgeTopics: \`${{ inputs.kafkaPurgeTopics }}\`" >> $GITHUB_STEP_SUMMARY + echo "- runDataPreparation: \`${{ inputs.runDataPreparation }}\`" >> $GITHUB_STEP_SUMMARY + echo "- runTests: \`${{ inputs.runJSTests }}\`" >> $GITHUB_STEP_SUMMARY + + create_runner: + name: Create Self-Hosted Runner + runs-on: ubuntu-22.04 + strategy: + matrix: + index: [1] + fail-fast: true + environment: ${{ inputs.environment }} + + steps: + - name: Start GitHub Runner + id: start_runner + uses: pagopa/interop-github-runner-aws-create-action@main + with: + environment: ${{ inputs.environment }} + aws_region: ${{ secrets.AWS_REGION }} + iam_role_arn: ${{ secrets.ECS_IAM_ROLE_ARN }} + ecs_cluster_name: ${{ secrets.ECS_CLUSTER_NAME }} + ecs_task_definition: ${{ secrets.ECS_TASK_DEFINITION }} + ecs_container_name: ${{ vars.ECS_TASK_CONTAINER_NAME }} + ecs_task_max_duration_seconds: ${{ vars.ECS_TASK_MAX_DURATION_SECONDS }} + ecs_task_subnet_id: ${{ secrets.SUBNET_ID }} + ecs_task_sec_group: ${{ secrets.SEC_GROUP_ID }} + pat_token: ${{ secrets.BOT_TOKEN }} + + + + + run_java_test: + name: Run Java Cucumber Test Suite + needs: [create_runner] + runs-on: [self-hosted, "run_id:${{ inputs.environment }}-${{ github.run_id }}"] + environment: ${{ inputs.environment }} + env: + ENVIRONMENT: ${{ vars.ENVIRONMENT }} + ST_VERBOSE_MODE: ${{ vars.ST_VERBOSE_MODE }} + + steps: + - name: Set up Maven + uses: s4u/setup-maven-action@6d44c18d67d9e1549907b8815efa5e4dada1801b # v1.12.0 + with: + java-version: 17 + maven-version: 3.9.8 + + - name: Clone the pn-b2b-client repo + id: clone_pn-b2b-client + shell: bash + run: | + echo "Cloning pn-b2b-client repo.." + git clone --depth 1 --branch ${{ inputs.javaBranchName }} https://github.com/pagopa/pn-b2b-client.git + echo "pn-b2b-client repo has been cloned" + + - name: Run QA tests + id: run_pn-b2b-client_tests + shell: bash + run: | + set -uo pipefail + echo "Running tests..." + cd ./pn-b2b-client/interop-qa-tests && mvn -Dtest=it.pagopa.pn.interop.cucumber.${{ inputs.javaTestSuite }} clean verify + + delete_runner: + name: Delete Self-Hosted Runner + needs: [create_runner, svc_version_check, data_prep, run_js_test, run_java_test] + if: ${{ always() }} + runs-on: ubuntu-22.04 + strategy: + matrix: + index: [1] + fail-fast: true + environment: ${{ inputs.environment }} + + steps: + - name: Stop Github Runner + id: stop_runner + uses: pagopa/interop-github-runner-aws-cleanup-action@main + with: + environment: ${{ inputs.environment }} + aws_region: ${{ secrets.AWS_REGION }} + iam_role_arn: ${{ secrets.ECS_IAM_ROLE_ARN }} + ecs_cluster_name: ${{ secrets.ECS_CLUSTER_NAME }} + pat_token: ${{ secrets.BOT_TOKEN }} From 350b926f7e752107c50a5751ada55159b84c5be2 Mon Sep 17 00:00:00 2001 From: Matteo Mancini Date: Mon, 17 Feb 2025 16:26:16 +0100 Subject: [PATCH 2/9] QA-5882: updated qa.yaml workflow --- .github/workflows/qa.yaml | 67 ++++++----------- .github/workflows/tracing.yaml | 127 --------------------------------- 2 files changed, 21 insertions(+), 173 deletions(-) delete mode 100644 .github/workflows/tracing.yaml diff --git a/.github/workflows/qa.yaml b/.github/workflows/qa.yaml index 33b243fad..bee795bed 100644 --- a/.github/workflows/qa.yaml +++ b/.github/workflows/qa.yaml @@ -4,7 +4,7 @@ on: workflow_dispatch: inputs: environment: - description: 'Environment to run tests against' + description: 'Environment where tests will be run' required: true type: environment testSuite: @@ -34,39 +34,30 @@ jobs: echo "- branch name: \`${{ github.ref_name }}\`" >> $GITHUB_STEP_SUMMARY echo "- testSuite: \`${{ inputs.testSuite }}\`" >> $GITHUB_STEP_SUMMARY - create_runner: - name: Create Self-Hosted Runner - runs-on: ubuntu-22.04 - environment: ${{ inputs.environment }} - - steps: - - name: Start GitHub Runner - id: start_runner - uses: pagopa/interop-github-runner-aws-create-action@main - with: - environment: ${{ inputs.environment }} - aws_region: ${{ secrets.AWS_REGION }} - iam_role_arn: ${{ secrets.ECS_IAM_ROLE_ARN }} - ecs_cluster_name: ${{ secrets.ECS_CLUSTER_NAME }} - ecs_task_definition: ${{ secrets.ECS_TASK_DEFINITION }} - ecs_container_name: ${{ vars.ECS_TASK_CONTAINER_NAME }} - ecs_task_max_duration_seconds: ${{ vars.ECS_TASK_MAX_DURATION_SECONDS }} - ecs_task_subnet_id: ${{ secrets.SUBNET_ID }} - ecs_task_sec_group: ${{ secrets.SEC_GROUP_ID }} - pat_token: ${{ secrets.BOT_TOKEN }} - run_test: name: Run Cucumber Test Suite - needs: create_runner - runs-on: [self-hosted, "run_id:${{ inputs.environment }}-${{ github.run_id }}"] + runs-on: ubuntu-22.04 environment: ${{ inputs.environment }} env: - ENVIRONMENT: qa + ENVIRONMENT: ${{ inputs.environment }} ST_VERBOSE_MODE: ${{ vars.ST_VERBOSE_MODE }} steps: - - name: Clone QA test repo - id: clone_qa_repo + - name: Configure AWS credentials + uses: aws-actions/configure-aws-credentials@v3 + with: + role-to-assume: arn:aws:iam::xxx:role/zzz + role-session-name: pn-b2b-client-${{ github.job }}-${{ github.run_id }} + aws-region: eu-south-1 + + - name: Set up Maven + uses: s4u/setup-maven-action@6d44c18d67d9e1549907b8815efa5e4dada1801b # v1.12.0 + with: + java-version: 17 + maven-version: 3.9.8 + + - name: Clone the pn-b2b-client repo + id: clone_pn-b2b-client uses: actions/checkout@v2 with: ref: ${{ github.ref_name }} # Branch name to clone @@ -76,23 +67,7 @@ jobs: id: run_qa_tests shell: bash run: | - echo "Run test" - ( cd ./pn-b2b-client/interop-qa-tests && ./mvnw -Dtest=it.pagopa.pn.interop.cucumber.${{ inputs.testSuite }} clean verify ) - - delete_runner: - name: Delete Self-Hosted Runner - needs: run_test - if: ${{ always() }} - runs-on: ubuntu-22.04 - environment: ${{ inputs.environment }} + set -uo pipefail + echo "Running tests..." + cd ./pn-b2b-client/interop-qa-tests && mvn -Dtest=it.pagopa.pn.interop.cucumber.InteropTracingTest clean verify - steps: - - name: Stop Github Runner - id: stop_runner - uses: pagopa/interop-github-runner-aws-cleanup-action@main - with: - environment: ${{ inputs.environment }} - aws_region: ${{ secrets.AWS_REGION }} - iam_role_arn: ${{ secrets.ECS_IAM_ROLE_ARN }} - ecs_cluster_name: ${{ secrets.ECS_CLUSTER_NAME }} - pat_token: ${{ secrets.BOT_TOKEN }} diff --git a/.github/workflows/tracing.yaml b/.github/workflows/tracing.yaml deleted file mode 100644 index 391108335..000000000 --- a/.github/workflows/tracing.yaml +++ /dev/null @@ -1,127 +0,0 @@ -name: Tracing Test - -on: - workflow_dispatch: - inputs: - environment: - description: 'Environment to run tests against' - required: true - type: environment - javaBranchName: - description: 'Provide the branch name for pn-b2b-client to clone' - required: false - default: main - type: string - - -defaults: - run: - shell: bash - -permissions: - id-token: write - contents: read - -env: - skip_checkUserMembership: "true" - skip_failNotSelectedEnvTagRef: "true" - SCRIPTS_FOLDER: "./scripts" - -jobs: - inputs: - runs-on: ubuntu-22.04 - environment: ${{ inputs.environment }} - - steps: - - name: Print Inputs - id: print_inputs - run: | - echo "- environment: \`${{ inputs.environment }}\`" >> $GITHUB_STEP_SUMMARY - echo "- normalized environment: \`${{ vars.NORM_ENV }}\`" >> $GITHUB_STEP_SUMMARY - echo "- ref: \`${{ github.ref }}\`" >> $GITHUB_STEP_SUMMARY - echo "- plat-dep versions: \`${{ vars.PLAT_DEP_VERSIONS_URL }}\`" >> $GITHUB_STEP_SUMMARY - echo "- kafkaPurgeTopics: \`${{ inputs.kafkaPurgeTopics }}\`" >> $GITHUB_STEP_SUMMARY - echo "- runDataPreparation: \`${{ inputs.runDataPreparation }}\`" >> $GITHUB_STEP_SUMMARY - echo "- runTests: \`${{ inputs.runJSTests }}\`" >> $GITHUB_STEP_SUMMARY - - create_runner: - name: Create Self-Hosted Runner - runs-on: ubuntu-22.04 - strategy: - matrix: - index: [1] - fail-fast: true - environment: ${{ inputs.environment }} - - steps: - - name: Start GitHub Runner - id: start_runner - uses: pagopa/interop-github-runner-aws-create-action@main - with: - environment: ${{ inputs.environment }} - aws_region: ${{ secrets.AWS_REGION }} - iam_role_arn: ${{ secrets.ECS_IAM_ROLE_ARN }} - ecs_cluster_name: ${{ secrets.ECS_CLUSTER_NAME }} - ecs_task_definition: ${{ secrets.ECS_TASK_DEFINITION }} - ecs_container_name: ${{ vars.ECS_TASK_CONTAINER_NAME }} - ecs_task_max_duration_seconds: ${{ vars.ECS_TASK_MAX_DURATION_SECONDS }} - ecs_task_subnet_id: ${{ secrets.SUBNET_ID }} - ecs_task_sec_group: ${{ secrets.SEC_GROUP_ID }} - pat_token: ${{ secrets.BOT_TOKEN }} - - - - - run_java_test: - name: Run Java Cucumber Test Suite - needs: [create_runner] - runs-on: [self-hosted, "run_id:${{ inputs.environment }}-${{ github.run_id }}"] - environment: ${{ inputs.environment }} - env: - ENVIRONMENT: ${{ vars.ENVIRONMENT }} - ST_VERBOSE_MODE: ${{ vars.ST_VERBOSE_MODE }} - - steps: - - name: Set up Maven - uses: s4u/setup-maven-action@6d44c18d67d9e1549907b8815efa5e4dada1801b # v1.12.0 - with: - java-version: 17 - maven-version: 3.9.8 - - - name: Clone the pn-b2b-client repo - id: clone_pn-b2b-client - shell: bash - run: | - echo "Cloning pn-b2b-client repo.." - git clone --depth 1 --branch ${{ inputs.javaBranchName }} https://github.com/pagopa/pn-b2b-client.git - echo "pn-b2b-client repo has been cloned" - - - name: Run QA tests - id: run_pn-b2b-client_tests - shell: bash - run: | - set -uo pipefail - echo "Running tests..." - cd ./pn-b2b-client/interop-qa-tests && mvn -Dtest=it.pagopa.pn.interop.cucumber.${{ inputs.javaTestSuite }} clean verify - - delete_runner: - name: Delete Self-Hosted Runner - needs: [create_runner, svc_version_check, data_prep, run_js_test, run_java_test] - if: ${{ always() }} - runs-on: ubuntu-22.04 - strategy: - matrix: - index: [1] - fail-fast: true - environment: ${{ inputs.environment }} - - steps: - - name: Stop Github Runner - id: stop_runner - uses: pagopa/interop-github-runner-aws-cleanup-action@main - with: - environment: ${{ inputs.environment }} - aws_region: ${{ secrets.AWS_REGION }} - iam_role_arn: ${{ secrets.ECS_IAM_ROLE_ARN }} - ecs_cluster_name: ${{ secrets.ECS_CLUSTER_NAME }} - pat_token: ${{ secrets.BOT_TOKEN }} From 3a24837eadfd3fb873d1a33fed9892d47e9999ef Mon Sep 17 00:00:00 2001 From: Matteo Mancini Date: Mon, 17 Feb 2025 17:14:34 +0100 Subject: [PATCH 3/9] QA-5882: improved retrieveTracingByStatus and retrieveTracingAndVerifyStatus methods --- .../cucumber/steps/tracing/TracingSteps.java | 28 +++++++++++++------ .../cucumber/tracing/interop-tracing.feature | 2 +- 2 files changed, 20 insertions(+), 10 deletions(-) diff --git a/interop-qa-tests/src/test/java/it/pagopa/pn/interop/cucumber/steps/tracing/TracingSteps.java b/interop-qa-tests/src/test/java/it/pagopa/pn/interop/cucumber/steps/tracing/TracingSteps.java index 32d554ef2..4da4bad11 100644 --- a/interop-qa-tests/src/test/java/it/pagopa/pn/interop/cucumber/steps/tracing/TracingSteps.java +++ b/interop-qa-tests/src/test/java/it/pagopa/pn/interop/cucumber/steps/tracing/TracingSteps.java @@ -94,6 +94,7 @@ public void retrieveTracingByStatusList(List statusList) { @When("viene recuperata la lista di tracing con stato {string}") public void retrieveTracingByStatus(String status) { retrieveTracing(List.of(TracingState.fromValue(status))); + Assertions.assertFalse(getTracingsResponse.getResults().isEmpty(), String.format("No Tracings were retrieved for the desired status: %s", status)); } public void retrieveTracing(List statusList) { @@ -230,28 +231,37 @@ public void waitForStatus(String state) { .filter(x -> x.getTracingId().equals(submitTracingResponse.getTracingId().toString())) .map(GetTracingsResponseResults::getState) .anyMatch(tracingState -> tracingState.equals(state)), - "" + String.format("The TracingId: %s did not reach the desired status: %s", submitTracingResponse.getTracingId().toString(), state) ); } @Then("viene recuperato il file di tracing appena caricato e si verifica che lo stato sia {string}") - public void retrieveTracingAndVerifyStatus(String status) { + public void retrieveTracingAndVerifyStatus(String state) { GetTracingsResponseResults result; int attempt = 0; int totalPages; try { do { - GetTracingsResponse getTracingsResponse = interopTracingClient.getTracings(attempt, LIMIT_VALUE, List.of(TracingState.fromValue(status))); - result = getTracingsResponse.getResults().stream() + GetTracingsResponse tracingsResponse = interopTracingClient.getTracings(attempt, LIMIT_VALUE, List.of()); + totalPages = tracingsResponse.getTotalCount().intValue(); + result = tracingsResponse.getResults().stream() .filter(x -> x.getTracingId().equals(submitTracingResponse.getTracingId().toString())) .findFirst() .orElse(null); - totalPages = getTracingsResponse.getTotalCount().intValue(); - if (result != null || getTracingsResponse.getResults().isEmpty()) break; - attempt++; - } while (attempt < totalPages); + + if (result != null) { + int finalAttempt = attempt; + pollingService.makePolling( + () -> interopTracingClient.getTracings(finalAttempt, LIMIT_VALUE, List.of()), + res -> res.getResults().stream().anyMatch(x -> x.getTracingId().equals(submitTracingResponse.getTracingId().toString()) && x.getState().equals(state)), + String.format("The TracingId: %s did not reach the desired status: %s", submitTracingResponse.getTracingId().toString(), state) + ); + break; + } else attempt++; + + } while (attempt < totalPages / LIMIT_VALUE + 1); if (result == null) { - throw new RuntimeException("Tracing ID not found after " + totalPages + " attempts!"); + throw new RuntimeException("Tracing ID not found after " + attempt + " attempts!"); } } catch (Exception e) { throw new RuntimeException("There was an error while retrieving the tracing file!"); diff --git a/interop-qa-tests/src/test/resources/it/pagopa/pn/cucumber/tracing/interop-tracing.feature b/interop-qa-tests/src/test/resources/it/pagopa/pn/cucumber/tracing/interop-tracing.feature index 16d3a1da1..f073f4c0d 100644 --- a/interop-qa-tests/src/test/resources/it/pagopa/pn/cucumber/tracing/interop-tracing.feature +++ b/interop-qa-tests/src/test/resources/it/pagopa/pn/cucumber/tracing/interop-tracing.feature @@ -94,7 +94,7 @@ Feature: Interop Tracing feature Scenario: [INTEROP-TRACING-11] Verifica stato endpoint di health When viene invocato l'endpoint di health con successo - @interopTracingCsv @ignore + @interopTracingCsv Scenario: [INTEROP-TRACING-12] Invio del file CSV tracing mancante utilizzando l'identificativo del file di tracing non inserito per una determinata data Given l'utenza "TENANT1" effettua le chiamate Given viene recuperata la lista di tracing con stato "MISSING" From 069a00ae167199ff543bfd74fd8102ed1345c8cd Mon Sep 17 00:00:00 2001 From: Matteo Mancini Date: Thu, 20 Feb 2025 14:24:21 +0100 Subject: [PATCH 4/9] QA-5882: updated role-to-assume property in order to use the secret stored in the Github env property --- .github/workflows/qa.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/qa.yaml b/.github/workflows/qa.yaml index bee795bed..68a384e88 100644 --- a/.github/workflows/qa.yaml +++ b/.github/workflows/qa.yaml @@ -46,7 +46,7 @@ jobs: - name: Configure AWS credentials uses: aws-actions/configure-aws-credentials@v3 with: - role-to-assume: arn:aws:iam::xxx:role/zzz + role-to-assume: ${{ secrets.ECS_IAM_ROLE_ARN }} role-session-name: pn-b2b-client-${{ github.job }}-${{ github.run_id }} aws-region: eu-south-1 From 1d6dcc4ff92567fc7e7ce3834e0cf2b0ca133d99 Mon Sep 17 00:00:00 2001 From: Matteo Mancini Date: Thu, 20 Feb 2025 14:30:10 +0100 Subject: [PATCH 5/9] QA-5882: added debug step --- .github/workflows/qa.yaml | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/.github/workflows/qa.yaml b/.github/workflows/qa.yaml index 68a384e88..08b06099d 100644 --- a/.github/workflows/qa.yaml +++ b/.github/workflows/qa.yaml @@ -43,6 +43,12 @@ jobs: ST_VERBOSE_MODE: ${{ vars.ST_VERBOSE_MODE }} steps: + - name: Debug AWS Role + run: | + echo "Role ARN length: ${#ECS_IAM_ROLE_ARN}" + env: + ECS_IAM_ROLE_ARN: ${{ secrets.ECS_IAM_ROLE_ARN }} + - name: Configure AWS credentials uses: aws-actions/configure-aws-credentials@v3 with: From a1cd44468fc5718e9a49fb8ae9c1121cf5fe8554 Mon Sep 17 00:00:00 2001 From: Matteo Mancini Date: Thu, 20 Feb 2025 15:18:40 +0100 Subject: [PATCH 6/9] QA-5882: updated environment --- .github/workflows/qa.yaml | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/.github/workflows/qa.yaml b/.github/workflows/qa.yaml index 08b06099d..6d3e0df9d 100644 --- a/.github/workflows/qa.yaml +++ b/.github/workflows/qa.yaml @@ -10,7 +10,7 @@ on: testSuite: description: 'Choose the test suite to run' required: false - default: NrtTest + default: InteropTracingTest type: string defaults: @@ -37,9 +37,8 @@ jobs: run_test: name: Run Cucumber Test Suite runs-on: ubuntu-22.04 - environment: ${{ inputs.environment }} + environment: test env: - ENVIRONMENT: ${{ inputs.environment }} ST_VERBOSE_MODE: ${{ vars.ST_VERBOSE_MODE }} steps: From 973325bcba2825de73fcfc322c979ca8669a26ef Mon Sep 17 00:00:00 2001 From: Matteo Mancini Date: Fri, 21 Feb 2025 14:29:11 +0100 Subject: [PATCH 7/9] QA-5882: replaced secrets to vars --- .github/workflows/qa.yaml | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/.github/workflows/qa.yaml b/.github/workflows/qa.yaml index 6d3e0df9d..4911527fb 100644 --- a/.github/workflows/qa.yaml +++ b/.github/workflows/qa.yaml @@ -37,8 +37,9 @@ jobs: run_test: name: Run Cucumber Test Suite runs-on: ubuntu-22.04 - environment: test - env: + environment: ${{ inputs.environment }} + env: + ENVIRONMENT: ${{ inputs.environment }} ST_VERBOSE_MODE: ${{ vars.ST_VERBOSE_MODE }} steps: @@ -46,12 +47,12 @@ jobs: run: | echo "Role ARN length: ${#ECS_IAM_ROLE_ARN}" env: - ECS_IAM_ROLE_ARN: ${{ secrets.ECS_IAM_ROLE_ARN }} + ECS_IAM_ROLE_ARN: ${{ vars.ECS_IAM_ROLE_ARN }} - name: Configure AWS credentials uses: aws-actions/configure-aws-credentials@v3 with: - role-to-assume: ${{ secrets.ECS_IAM_ROLE_ARN }} + role-to-assume: ${{ vars.ECS_IAM_ROLE_ARN }} role-session-name: pn-b2b-client-${{ github.job }}-${{ github.run_id }} aws-region: eu-south-1 From 6b592163270732e7ef8504a67b68035705d5dc35 Mon Sep 17 00:00:00 2001 From: Matteo Mancini Date: Fri, 21 Feb 2025 14:55:44 +0100 Subject: [PATCH 8/9] QA-5882: added debug steps --- .github/workflows/qa.yaml | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/.github/workflows/qa.yaml b/.github/workflows/qa.yaml index 4911527fb..a0c6a6c2e 100644 --- a/.github/workflows/qa.yaml +++ b/.github/workflows/qa.yaml @@ -62,6 +62,12 @@ jobs: java-version: 17 maven-version: 3.9.8 + - name: Debug Branch Name + run: | + echo "branch name: $branchName" + env: + branchName: ${{ github.ref_name }} + - name: Clone the pn-b2b-client repo id: clone_pn-b2b-client uses: actions/checkout@v2 @@ -69,11 +75,18 @@ jobs: ref: ${{ github.ref_name }} # Branch name to clone fetch-depth: 1 # Clone only the last commit + - name: Print current directory + run: | + echo "Current working directory:" + pwd + echo "Contents of the directory:" + ls -la + - name: Run QA tests id: run_qa_tests shell: bash run: | set -uo pipefail echo "Running tests..." - cd ./pn-b2b-client/interop-qa-tests && mvn -Dtest=it.pagopa.pn.interop.cucumber.InteropTracingTest clean verify + cd ./interop-qa-tests && mvn -Dtest=it.pagopa.pn.interop.cucumber.InteropTracingTest clean verify From 434c8b89e96711d64d302a70f008065201b22fba Mon Sep 17 00:00:00 2001 From: Matteo Mancini Date: Fri, 21 Feb 2025 15:02:17 +0100 Subject: [PATCH 9/9] QA-5882: removed no longer required steps and commented the pending scenario since no tracings are present with this status --- .github/workflows/qa.yaml | 19 ------------------- .../cucumber/tracing/interop-tracing.feature | 2 +- 2 files changed, 1 insertion(+), 20 deletions(-) diff --git a/.github/workflows/qa.yaml b/.github/workflows/qa.yaml index a0c6a6c2e..d6a5affe0 100644 --- a/.github/workflows/qa.yaml +++ b/.github/workflows/qa.yaml @@ -43,12 +43,6 @@ jobs: ST_VERBOSE_MODE: ${{ vars.ST_VERBOSE_MODE }} steps: - - name: Debug AWS Role - run: | - echo "Role ARN length: ${#ECS_IAM_ROLE_ARN}" - env: - ECS_IAM_ROLE_ARN: ${{ vars.ECS_IAM_ROLE_ARN }} - - name: Configure AWS credentials uses: aws-actions/configure-aws-credentials@v3 with: @@ -62,12 +56,6 @@ jobs: java-version: 17 maven-version: 3.9.8 - - name: Debug Branch Name - run: | - echo "branch name: $branchName" - env: - branchName: ${{ github.ref_name }} - - name: Clone the pn-b2b-client repo id: clone_pn-b2b-client uses: actions/checkout@v2 @@ -75,13 +63,6 @@ jobs: ref: ${{ github.ref_name }} # Branch name to clone fetch-depth: 1 # Clone only the last commit - - name: Print current directory - run: | - echo "Current working directory:" - pwd - echo "Contents of the directory:" - ls -la - - name: Run QA tests id: run_qa_tests shell: bash diff --git a/interop-qa-tests/src/test/resources/it/pagopa/pn/cucumber/tracing/interop-tracing.feature b/interop-qa-tests/src/test/resources/it/pagopa/pn/cucumber/tracing/interop-tracing.feature index f073f4c0d..e82d39685 100644 --- a/interop-qa-tests/src/test/resources/it/pagopa/pn/cucumber/tracing/interop-tracing.feature +++ b/interop-qa-tests/src/test/resources/it/pagopa/pn/cucumber/tracing/interop-tracing.feature @@ -44,7 +44,7 @@ Feature: Interop Tracing feature | status | | MISSING | | COMPLETED | - | PENDING | +# | PENDING | Line commented since no pending tracings are present | ERROR | # Questo test va eseguito usando un'utenza con cui non sono mai stati caricati file di tracing