From ff6859e0c7f55b0af48a8d826ce86947da8ca045 Mon Sep 17 00:00:00 2001 From: Emir Hodzic Date: Thu, 10 Oct 2024 14:18:16 +0200 Subject: [PATCH] test(cat-voices): add allure report to slack (#989) --- .github/workflows/nightly-ci.yml | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) diff --git a/.github/workflows/nightly-ci.yml b/.github/workflows/nightly-ci.yml index 71e4bc44db8..cdf6d7a377e 100644 --- a/.github/workflows/nightly-ci.yml +++ b/.github/workflows/nightly-ci.yml @@ -4,8 +4,7 @@ on: schedule: - cron: '0 0 * * *' # Runs every day at 00:00 workflow_dispatch: - branches: - - main + permissions: id-token: write @@ -118,4 +117,15 @@ jobs: with: repository: gh-pages-dir branch: gh-pages - pull_args: --rebase -X ours \ No newline at end of file + pull_args: --rebase -X ours + + - name: Send Slack notification + if: ${{ always() && steps.allure.outputs.report_url }} + uses: slackapi/slack-github-action@v1.23.0 + with: + payload: | + { + "text": ":rocket: *Test Report*\n<${{ steps.allure.outputs.report_url }}|Click here to view the Allure report>\n*Passed:* ${{ steps.allure.outputs.test_result_passed }}/ ${{ steps.allure.outputs.test_result_total }}\n*Failed:* ${{ steps.allure.outputs.test_result_failed }}/ ${{ steps.allure.outputs.test_result_total }}" + } + env: + SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }} \ No newline at end of file