name: test on: push: branches: - master schedule: - cron: "00 16 07 * *" # = monthly workflow_dispatch: jobs: test: runs-on: ubuntu-latest steps: - name: Checkout uses: actions/checkout@v3 - name: Update pip run: python3 -m pip install -U pip - name: Install requirements*.txt run: | for requirements_txt in requirements*.txt; do python3 -m pip install -r $requirements_txt; done - name: Test run: | cd src mkdir -p ../test-results python3 -m pytest --junitxml=../test-results/junit.xml -o junit_family=legacy - name: Upload test results uses: actions/upload-artifact@v2 if: success() || failure() with: name: test-results path: test-results report: runs-on: ubuntu-latest needs: test steps: - uses: dorny/test-reporter@v1 with: artifact: test-results name: Tests path: '*.xml' reporter: jest-junit