Skip to content

Commit

Permalink
Changed matrix to run based on RPYC_BIND_THREADS setting and python v…
Browse files Browse the repository at this point in the history
…ersion. Also disabled fail-fast
  • Loading branch information
comrumino committed Jun 24, 2024
1 parent 843b208 commit a5afa86
Showing 1 changed file with 12 additions and 9 deletions.
21 changes: 12 additions & 9 deletions .github/workflows/python-app.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,22 +10,23 @@ on:
branches: [ master ]

jobs:
python-unittest-all-versions:
lint-and-unittest:

runs-on: ubuntu-latest

strategy:
fail-fast: false
matrix:
python-version: ["3.7", "3.8", "3.9", "3.10", "3.11", "3.12"]
RPYC_BIND_THREADS: ["true", "false"]
python_version: ["3.7", "3.8", "3.9", "3.10", "3.11", "3.12"]

steps:
- uses: actions/checkout@v3

- name: Set up Python ${{ matrix.python-version }}
- name: Set up Python ${{ matrix.python_version }}
uses: actions/setup-python@v4

with:
python-version: ${{ matrix.python-version }}
python_version: ${{ matrix.python_version }}
- name: Install dependencies
run: |
python -m pip install --upgrade pip setuptools flake8
Expand All @@ -46,9 +47,11 @@ jobs:
ssh-keygen -q -f ~/.ssh/id_rsa -N ''
cat ~/.ssh/id_rsa.pub >> ~/.ssh/authorized_keys
uname -a
- name: Bind threads tests with unittest
run: |
RPYC_BIND_THREADS="true" python -m unittest discover -v
- name: Default tests with unittest
- name: Run unittest with default settings
if: ${{ matrix.RPYC_BIND_THREADS == 'false' }}
run: |
python -m unittest discover -v
- name: Run unittest with RPYC_BIND_THREADS enabled
if: ${{ matrix.RPYC_BIND_THREADS == 'true' }}
run: |
RPYC_BIND_THREADS="${{ matrix.RPYC_BIND_THREADS }}" python -m unittest discover -v

0 comments on commit a5afa86

Please sign in to comment.