From 26a324e647bdf6a80d0281203374a6525ab84503 Mon Sep 17 00:00:00 2001 From: Szymon Mrozek Date: Tue, 25 Jul 2023 14:04:56 +0200 Subject: [PATCH 1/4] chore: Upload unit tests reports to DataDog (WPB-3489) --- .github/workflows/publish-test-results.yml | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/.github/workflows/publish-test-results.yml b/.github/workflows/publish-test-results.yml index 064ef5eb307..fef2b69f57d 100644 --- a/.github/workflows/publish-test-results.yml +++ b/.github/workflows/publish-test-results.yml @@ -64,3 +64,14 @@ jobs: CHECKS_LINK="https://github.com/wireapp/wire-android-reloaded/actions/runs/${{ github.event.workflow_run.id }}" PR_NUMBER=$(jq --raw-output .pull_request.number "$EVENT_FILE_PATH") gh pr comment "$PR_NUMBER" --body "APKs built during tests are available [here]($CHECKS_LINK). Scroll down to **Artifacts**!" + + - uses: actions/setup-node@v3 + with: + node-version: 18 + - name: Install datadog-ci + run: npm install -g @datadog/datadog-ci + - name: "Upload results" + env: + DD_API_KEY: ${{ secrets.DD_API_KEY }} + run: | + DATADOG_API_KEY="${DD_API_KEY}" DD_ENV=ci DATADOG_SITE=datadoghq.eu datadog-ci junit upload --service wire-ios-android ./*.xml From eee5ecd82a08392f746728d5ab2d37358f3edf73 Mon Sep 17 00:00:00 2001 From: Szymon Mrozek Date: Tue, 25 Jul 2023 16:38:55 +0200 Subject: [PATCH 2/4] Correct typo --- .github/workflows/publish-test-results.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/publish-test-results.yml b/.github/workflows/publish-test-results.yml index fef2b69f57d..de598484a14 100644 --- a/.github/workflows/publish-test-results.yml +++ b/.github/workflows/publish-test-results.yml @@ -74,4 +74,4 @@ jobs: env: DD_API_KEY: ${{ secrets.DD_API_KEY }} run: | - DATADOG_API_KEY="${DD_API_KEY}" DD_ENV=ci DATADOG_SITE=datadoghq.eu datadog-ci junit upload --service wire-ios-android ./*.xml + DATADOG_API_KEY="${DD_API_KEY}" DD_ENV=ci DATADOG_SITE=datadoghq.eu datadog-ci junit upload --service wire-android ./*.xml From 4ef5c5c0c98f94f41860af0059863c1bd2bd307f Mon Sep 17 00:00:00 2001 From: Szymon Mrozek Date: Wed, 26 Jul 2023 12:38:13 +0200 Subject: [PATCH 3/4] Specify path for junit results --- .github/workflows/publish-test-results.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/publish-test-results.yml b/.github/workflows/publish-test-results.yml index de598484a14..ff3e3fdd1be 100644 --- a/.github/workflows/publish-test-results.yml +++ b/.github/workflows/publish-test-results.yml @@ -74,4 +74,4 @@ jobs: env: DD_API_KEY: ${{ secrets.DD_API_KEY }} run: | - DATADOG_API_KEY="${DD_API_KEY}" DD_ENV=ci DATADOG_SITE=datadoghq.eu datadog-ci junit upload --service wire-android ./*.xml + DATADOG_API_KEY="${DD_API_KEY}" DD_ENV=ci DATADOG_SITE=datadoghq.eu datadog-ci junit upload --service wire-android ./artifacts/test-results/**/*.xml From f9d07f20b7af54d4fd6902763c1e4231fdbc0f3a Mon Sep 17 00:00:00 2001 From: Szymon Mrozek Date: Wed, 26 Jul 2023 13:12:06 +0200 Subject: [PATCH 4/4] Fix formatting --- .github/workflows/publish-test-results.yml | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/.github/workflows/publish-test-results.yml b/.github/workflows/publish-test-results.yml index ff3e3fdd1be..73d415c4c8b 100644 --- a/.github/workflows/publish-test-results.yml +++ b/.github/workflows/publish-test-results.yml @@ -66,12 +66,12 @@ jobs: gh pr comment "$PR_NUMBER" --body "APKs built during tests are available [here]($CHECKS_LINK). Scroll down to **Artifacts**!" - uses: actions/setup-node@v3 - with: - node-version: 18 + with: + node-version: 18 - name: Install datadog-ci - run: npm install -g @datadog/datadog-ci + run: npm install -g @datadog/datadog-ci - name: "Upload results" - env: - DD_API_KEY: ${{ secrets.DD_API_KEY }} - run: | - DATADOG_API_KEY="${DD_API_KEY}" DD_ENV=ci DATADOG_SITE=datadoghq.eu datadog-ci junit upload --service wire-android ./artifacts/test-results/**/*.xml + env: + DD_API_KEY: ${{ secrets.DD_API_KEY }} + run: | + DATADOG_API_KEY="${DD_API_KEY}" DD_ENV=ci DATADOG_SITE=datadoghq.eu datadog-ci junit upload --service wire-android ./artifacts/test-results/**/*.xml