Skip to content
Open
Show file tree
Hide file tree
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
36 changes: 34 additions & 2 deletions .github/workflows/testsPython.yml
Original file line number Diff line number Diff line change
Expand Up @@ -68,12 +68,44 @@ jobs:
# on the test results.
notifications:
needs: python-unit-tests
if: always()
runs-on: ubuntu-latest
steps:
# Notifications in Job Summary panel of the workflow run
- name: Notify on test results
run: |
if [ "${{ needs.python-unit-tests.result }}" == "success" ]; then
echo "success notifications go here"
echo "## Tests Passed ✅" >> $GITHUB_STEP_SUMMARY
echo "All unit tests succeeded." >> $GITHUB_STEP_SUMMARY
else
echo "failure notifications go here"
echo "## Tests Failed ❌" >> $GITHUB_STEP_SUMMARY
echo "Check logs for details." >> $GITHUB_STEP_SUMMARY
fi
# Email notification using Brevo when tests pass, BREVO_API_KEY is set in repository secrets
- name: Send success email
if: ${{ needs.python-unit-tests.result == 'success' }}
run: |
curl -X POST https://api.brevo.com/v3/smtp/email \
-H "accept: application/json" \
-H "api-key: ${{ secrets.BREVO_API_KEY }}" \
-H "content-type: application/json" \
-d '{
"sender": { "email": "info@runningresults.net" },
"to": [{ "email": "yongchuangchen@gmail.com" }],
"subject": "Tests Passed ✅",
"htmlContent": "<p>All tests passed successfully.</p>"
}'
# Email notification using Brevo when tests fail, BREVO_API_KEY is set in repository secrets
- name: Send failure email
if: ${{ needs.python-unit-tests.result == 'failure' }}
run: |
curl -X POST https://api.brevo.com/v3/smtp/email \
-H "accept: application/json" \
-H "api-key: ${{ secrets.BREVO_API_KEY }}" \
-H "content-type: application/json" \
-d '{
"sender": { "email": "info@runningresults.net" },
"to": [{ "email": "yongchuangchen@gmail.com" }],
"subject": "Tests Failed ❌",
"htmlContent": "<p>Tests failed. Check logs in GitHub Actions.</p>"
}'
7 changes: 7 additions & 0 deletions agentic-ai-workflow.code-workspace
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
{
"folders": [
{
"path": "."
}
]
}