OCDS Data Review Tool live tests #1100
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: OCDS Data Review Tool live tests | |
on: | |
workflow_dispatch: | |
schedule: | |
# * is a special character in YAML so you have to quote this string | |
- cron: "0 0 * * *" | |
jobs: | |
build: | |
if: github.event_name == 'push' || github.event.pull_request.head.repo.full_name != github.repository | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
repository: open-contracting/cove-ocds | |
- uses: actions/setup-python@v4 | |
with: | |
python-version: '3.10' | |
cache: pip | |
cache-dependency-path: '**/requirements*.txt' | |
- run: pip install -r requirements_dev.txt | |
- env: | |
CUSTOM_SERVER_URL: https://review.standard.open-contracting.org/ | |
DJANGO_SETTINGS_MODULE: cove_project.settings | |
run: pytest tests/test_functional.py | |
- if: failure() | |
uses: dawidd6/action-send-mail@v3 | |
with: | |
server_address: ${{ secrets.MAIL_HOST }} | |
server_port: ${{ secrets.MAIL_PORT }} | |
username: ${{ secrets.MAIL_USERNAME }} | |
password: ${{ secrets.MAIL_PASSWORD }} | |
subject: "GitHub Actions: ${{ github.repository }} ${{ github.workflow }} failed!" | |
body: ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }} | |
to: [email protected] | |
from: GitHub Actions <[email protected]> |