Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 23 additions & 1 deletion .github/workflows/auto-simple-suite.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -36,10 +36,32 @@ jobs:
path: playwright-report/
retention-days: 7

post-slack-notification-started:
runs-on: ubuntu-latest
steps:
- name: Post to Slack
env:
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }}
run: |
curl -X POST -H 'Content-type: application/json' \
--data '{"text":"Simple suite results are ready"}' \
--data '{"text":"The simple suite pipeline started"}' \
$SLACK_WEBHOOK_URL

post-slack-notification-results:
runs-on: ubuntu-latest
needs: run-simple-suite
if: always()
steps:
- name: Post to Slack
env:
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }}
run: |
if [ "${{ needs.run-simple-suite.result }}" == "success" ]; then
MESSAGE="The simple suite pipeline succeeded"
elif [ "${{ needs.run-simple-suite.result }}" == "failure" ]; then
MESSAGE="The simple suite pipeline failed"
fi

curl -X POST -H 'Content-type: application/json' \
--data "{\"text\":\"$MESSAGE\"}" \
$SLACK_WEBHOOK_URL