CI experiment #22
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
# This is a basic workflow to help you get started with Actions | |
name: CI experiment | |
# Controls when the action will run. | |
on: | |
workflow_dispatch: | |
jobs: | |
test_run: | |
runs-on: [lab-mac] | |
strategy: | |
matrix: | |
python_version: ["3.10", "3.11", "3.12"] | |
fail-fast: false | |
env: | |
PYTHON_VERSION: ${{ matrix.python_version }} | |
TEST_FILE: Client_sanity_mac-${{github.run_number}}-${{ matrix.python_version }} | |
timeout-minutes: 120 | |
steps: | |
- name: Check out sources | |
uses: actions/checkout@v4 | |
- name: Setup python environment | |
run: | | |
$(brew --prefix)/bin/python${PYTHON_VERSION} -m venv venv | |
source venv/bin/activate | |
- name: Upgrade pip | |
run: | | |
venv/bin/pip install --upgrade pip | |
- name: install dependencies | |
run: | | |
venv/bin/pip install pytest | |
venv/bin/pip install pytest-qt | |
- name: install dependencies | |
run: | | |
venv/bin/pip list | |
- name: Install client | |
run: | | |
venv/bin/pip install -e . | |
- name: Run test suite | |
run: venv/bin/python -m pytest --verbose --html=${{env.TEST_FILE}}.html --junit-xml ${{env.TEST_FILE}}.xml | |
- name: Upload test file | |
if: always() | |
uses: actions/upload-artifact@v4 | |
with: | |
name: ${{env.TEST_FILE}}_results | |
if-no-files-found: warn | |
path: | | |
${{env.TEST_FILE}}.html | |
${{env.TEST_FILE}}.xml | |
assets/style.css | |
- name: Pretty print test results | |
if: always() | |
uses: pmeier/pytest-results-action@main | |
with: | |
path: ${{env.TEST_FILE}}.xml | |
summary: true | |
title: Test results |