Bump the actions group with 6 updates (#31) #259
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: Tests | |
concurrency: | |
group: ${{ github.workflow }}-${{ github.event.number }}-${{ github.event.ref }} | |
cancel-in-progress: true | |
on: | |
push: | |
branches: ['**'] | |
pull_request: | |
branches: ['**'] | |
create: | |
branches: [main] | |
tags: ['**'] | |
jobs: | |
pytest: | |
timeout-minutes: 20 | |
runs-on: ${{ matrix.os }} | |
strategy: | |
fail-fast: false | |
matrix: | |
os: [ubuntu-latest, windows-latest, macos-latest] | |
python-version: ["3.12"] | |
mne-version: [mne-main] | |
qt: [PyQt6] | |
include: | |
- os: macos-latest | |
python-version: "3.11" | |
mne-version: mne-stable | |
qt: PyQt6 | |
# Old (and PyQt5) | |
- os: ubuntu-latest | |
python-version: "3.10" | |
mne-version: mne-stable | |
qt: PyQt5 | |
# PySide6 | |
- os: ubuntu-latest | |
python-version: "3.11" | |
mne-version: mne-main | |
qt: PySide6 | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set up Python ${{ matrix.python-version }} | |
uses: actions/setup-python@v5 | |
with: | |
python-version: ${{ matrix.python-version }} | |
- uses: pyvista/setup-headless-display-action@main | |
with: | |
qt: true | |
- name: Install Python dependencies using pip | |
run: python -m pip install --upgrade pip setuptools_scm setuptools | |
- name: Clone MNE stable | |
if: "matrix.mne-version == 'mne-stable'" | |
run: git clone --single-branch --branch maint/1.7 https://github.com/mne-tools/mne-python.git | |
- name: Clone MNE main | |
if: "matrix.mne-version == 'mne-main'" | |
run: git clone --single-branch --branch main https://github.com/mne-tools/mne-python.git | |
- run: pip install -ve ./mne-python | |
- run: pip install -v ${{ matrix.qt }}!=6.6.0 "PyQt6-Qt6!=6.6.0,!=6.7.0" | |
- run: pip install -ve .[tests] | |
- run: mne sys_info | |
# Check Qt | |
- run: ./tools/check_qt_import.sh $MNE_QT_BACKEND | |
if: ${{ env.MNE_QT_BACKEND != '' }} | |
name: Check Qt | |
shell: bash | |
- run: python -c "import mne_gui_addons; print(mne_gui_addons.__version__)" | |
- run: ./tools/get_testing_version.sh | |
working-directory: mne-python | |
shell: bash | |
name: 'Get testing version' | |
- uses: actions/cache@v4 | |
with: | |
key: ${{ env.TESTING_VERSION }} | |
path: ~/mne_data | |
name: 'Cache testing data' | |
- run: ./tools/github_actions_download.sh | |
shell: bash | |
working-directory: mne-python | |
- name: Run pytest | |
run: pytest mne_gui_addons --cov-report=xml | |
- name: Upload coverage stats to codecov | |
uses: codecov/codecov-action@v4 | |
with: | |
token: ebcd818a-7a71-470d-b667-7cd9c3003c7d | |
if: success() || failure() |