Skip to content

Commit

Permalink
Built the Python version matrix for the Windows tests using the proje…
Browse files Browse the repository at this point in the history
…ct config file.
  • Loading branch information
nessita committed Jul 17, 2024
1 parent 0e49a8c commit 4420500
Showing 1 changed file with 14 additions and 2 deletions.
16 changes: 14 additions & 2 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,12 18,24 @@ permissions:
contents: read

jobs:
matrix_prep:
runs-on: ubuntu-latest
outputs:
python_versions_output: ${{ steps.set-matrix.outputs.python_versions }}
steps:
- name: Checkout code
uses: actions/checkout@v4
- id: set-matrix
run: |
python_versions=$(sed -n "s/^.*Programming Language :: Python :: \([[:digit:]]\ \.[[:digit:]]\ \).*$/'\1', /p" pyproject.toml | tr -d '\n' | sed 's/, $//g')
echo "Supported Python versions: $python_versions"
echo "python_versions=[$python_versions]" >> "$GITHUB_OUTPUT"
windows:
runs-on: windows-latest
needs: matrix_prep
strategy:
matrix:
python-version:
- '3.12'
python-version: ${{ fromJson(needs.matrix_prep.outputs.python_versions_output) }}
name: Windows, SQLite, Python ${{ matrix.python-version }}
steps:
- name: Checkout
Expand Down

0 comments on commit 4420500

Please sign in to comment.