Skip to content

Commit

Permalink
👷 try to modify test workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
nquetschlich committed Apr 29, 2024
1 parent dc8e1df commit fd40009
Showing 1 changed file with 75 additions and 9 deletions.
84 changes: 75 additions & 9 deletions .github/workflows/pretrained_model.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,19 +11,85 @@ concurrency:
cancel-in-progress: true

jobs:
run:

dist:
name: 📦 Check
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
submodules: recursive
fetch-depth: 0
- name: Setup Python
uses: actions/setup-python@v5
- if: ${{ inputs.setup-z3 }}
name: Setup Z3
uses: cda-tum/setup-z3@v1
with:
python-version: "3.10"
- name: Install MQT Predictor
run: pip install .[test]
- name: Run Pre-Trained Models
run: pytest -v tests/test_pretrained_models.py
version: ${{ inputs.z3-version }}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
GITHUB_TOKEN: ${{ github.token }}
- name: Set up mold as linker (Linux only)
uses: rui314/setup-mold@v1
- uses: hynek/build-and-inspect-python-package@v2
id: baipp
- name: 🐍 Determine maximum supported Python version
run: echo "max-python-version=$(echo '${{ steps.baipp.outputs.supported_python_classifiers_json_array }}' | jq --raw-output '.[-1]')" >> $GITHUB_OUTPUT
id: max-python-version
outputs:
python-versions: ${{ steps.baipp.outputs.supported_python_classifiers_json_array }}
max-python-version: ${{ steps.max-python-version.outputs.max-python-version }}

python-tests-ubuntu:
name: 🐧 ${{ matrix.python-version }}
needs: dist
strategy:
fail-fast: false
matrix:
python-version: ${{ fromJson(needs.dist.outputs.python-versions) }}
uses: ./.github/workflows/reusable-python-tests.yml
with:
runs-on: ubuntu-latest
python-version: ${{ matrix.python-version }}
setup-z3: ${{ inputs.setup-z3 }}
z3-version: ${{ inputs.z3-version }}
secrets:
token: ${{ secrets.token }}

python-tests-macos:
name: 🍎 ${{ matrix.python-version }} ${{ matrix.runs-on }}
needs: [dist]
strategy:
fail-fast: false
matrix:
python-version:
- ${{ fromJson(needs.dist.outputs.python-versions)[0] }}
- ${{ needs.dist.outputs.max-python-version }}
runs-on: [macos-13] # test Intel architecture
include:
- runs-on: macos-14 # test Apple Silicon architecture
python-version: ${{ needs.dist.outputs.max-python-version }} # testing Apple Silicon on 3.8 is blocked by https://github.com/actions/setup-python/issues/808
uses: ./.github/workflows/reusable-python-tests.yml
with:
runs-on: ${{ matrix.runs-on }}
python-version: ${{ matrix.python-version }}
setup-z3: ${{ inputs.setup-z3 }}
z3-version: ${{ inputs.z3-version }}
secrets:
token: ${{ secrets.token }}

python-tests-windows:
name: 🏁 ${{ matrix.python-version }}
needs: [dist]
strategy:
fail-fast: false
matrix:
python-version:
- ${{ fromJson(needs.dist.outputs.python-versions)[0] }}
- ${{ needs.dist.outputs.max-python-version }}
uses: ./.github/workflows/reusable-python-tests.yml
with:
runs-on: windows-latest
python-version: ${{ matrix.python-version }}
setup-z3: ${{ inputs.setup-z3 }}
z3-version: ${{ inputs.z3-version }}
secrets:
token: ${{ secrets.token }}

0 comments on commit fd40009

Please sign in to comment.