Skip to content

Commit

Permalink
Try adding a matrix to our jobs
Browse files Browse the repository at this point in the history
  • Loading branch information
mgoin committed Jul 11, 2023
1 parent 286574f commit 46b552d
Showing 1 changed file with 40 additions and 9 deletions.
49 changes: 40 additions & 9 deletions .github/workflows/test-check.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,59 +13,90 @@ on:
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:

concurrency:
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
cancel-in-progress: true

env:
SPARSEZOO_TEST_MODE: true
NM_DISABLE_ANALYTICS: "true"

jobs:
base-tests:
runs-on: ubuntu-20.04
strategy:
fail-fast: false
matrix:
python-version: [3.8, 3.9]
os: [ubuntu-20.04]
runs-on: ${{ matrix.os }}
steps:
- name: Setup Python ${{ matrix.python-version }}
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
- uses: actions/checkout@v2
- uses: actions/checkout@v2
with:
repository: "neuralmagic/sparsezoo"
path: "sparsezoo"
ref: ${{needs.test-setup.outputs.branch}}
- name: "⚙️ Install sparsezoo dependencies"
run: pip3 install -U pip && pip3 install setuptools sparsezoo/
run: pip install sparsezoo/
- name: "Clean sparsezoo directory"
run: rm -r sparsezoo/
- name: ⚙️ Install dependencies
run: pip3 install .[dev,server,image_classification,transformers] opencv-python
run: pip install .[dev,server,image_classification,transformers] opencv-python
- name: Run base tests
run: make test
cli-smoke-tests:
runs-on: ubuntu-20.04
strategy:
fail-fast: false
matrix:
python-version: [3.8, 3.9]
os: [ubuntu-20.04]
runs-on: ${{ matrix.os }}
steps:
- name: Setup Python ${{ matrix.python-version }}
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
- uses: actions/checkout@v2
- uses: actions/checkout@v2
with:
repository: "neuralmagic/sparsezoo"
path: "sparsezoo"
ref: ${{needs.test-setup.outputs.branch}}
- name: "⚙️ Install sparsezoo dependencies"
run: pip3 install -U pip && pip3 install setuptools sparsezoo/
run: pip install sparsezoo/
- name: "Clean sparsezoo directory"
run: rm -r sparsezoo/
- name: ⚙️ Install dependencies
run: pip3 install .[dev,server,image_classification,transformers]
run: pip install .[dev,server,image_classification,transformers]
- name: Run CLI smoke tests
run: PYTEST_ARGS="-m smoke" make test TARGETS=cli,nobase
integrations-tests:
runs-on: ubuntu-20.04
strategy:
fail-fast: false
matrix:
python-version: [3.8, 3.9]
os: [ubuntu-20.04]
runs-on: ${{ matrix.os }}
steps:
- name: Setup Python ${{ matrix.python-version }}
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
- uses: actions/checkout@v2
- uses: actions/checkout@v2
with:
repository: "neuralmagic/sparsezoo"
path: "sparsezoo"
ref: ${{needs.test-setup.outputs.branch}}
- name: "⚙️ Install sparsezoo dependencies"
run: pip3 install -U pip && pip3 install setuptools sparsezoo/
run: pip install sparsezoo/
- name: "Clean sparsezoo directory"
run: rm -r sparsezoo/
- name: ⚙️ Install dependencies
run: pip3 install .[dev,server,image_classification,transformers,haystack]
run: pip install .[dev,server,image_classification,transformers,haystack]
- name: Run integrations tests
run: make test_integrations

0 comments on commit 46b552d

Please sign in to comment.