Skip to content

.github/workflows/scheduled-full-ci.yml #4

.github/workflows/scheduled-full-ci.yml

.github/workflows/scheduled-full-ci.yml #4

name: QMI Python CI full test runner
on:
schedule:
# Schedule for every Monday at 7am
- cron: "0 7 * * 1"
jobs:
full-test:
strategy:
max-parallel: 1
matrix:
python-version: ["3.8", "3.9", "3.10", "3.11"]
uses: ./.github/workflows/reusable-ci-workflows.yml
with:
python-version: ${{ matrix.python-version }}
ref: ${{ github.head-ref }}
unit-tests:
runs-on: ubuntu-latest
needs: full-test
steps:
- name: Checkout code
uses: actions/checkout@v4
with:
ref: ${{ inputs.ref }}
- name: Run unit tests and generate report
if: always()
run: |
pip install .
pip install unittest-xml-reporting
python -m xmlrunner --output-file testresults.xml discover --start-directory=tests --pattern="test_*.py"
- name: Upload unit test results
if: always()
uses: actions/upload-artifact@v4
with:
name: unit-test-results-${{ matrix.python-version }}
path: testresults.xml