Skip to content

Commit

Permalink
Test on MacOS in CI
Browse files Browse the repository at this point in the history
  • Loading branch information
cbourjau committed Oct 6, 2023
1 parent d2be26a commit 624eaef
Showing 1 changed file with 34 additions and 6 deletions.
40 changes: 34 additions & 6 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
name: CI
on: [push]

on:
pull_request:
push:
branches:
- main
# Automatically stop old builds on the same branch/PR
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

defaults:
run:
Expand All @@ -24,7 +24,7 @@ jobs:
- name: Run pre-commit checks
uses: pre-commit/[email protected]

tests:
tests-linux:
name: "Linux - unit tests - Python ${{ matrix.PYTHON_VERSION }}"
runs-on: ubuntu-latest
env:
Expand Down Expand Up @@ -52,6 +52,34 @@ jobs:
pip install .
pytest
tests-macos:
name: "MacOS - unit tests - Python ${{ matrix.PYTHON_VERSION }}"
runs-on: macos-latest
env:
CI: True
strategy:
fail-fast: true
matrix:
PYTHON_VERSION: ['3.11']
steps:
- name: Checkout branch
uses: actions/checkout@v4
with:
ref: ${{ github.head_ref }}
- uses: conda-incubator/setup-miniconda@v2
with:
python-version: ${{ matrix.PYTHON_VERSION }}
miniforge-variant: Mambaforge
miniforge-version: 4.11.0-2
use-mamba: true
environment-file: environment.yml
activate-environment: spox
- name: Run unit tests
shell: bash -l {0}
run: |
pip install .
pytest
opset-generation:
name: "Linux - opset generation - Python ${{ matrix.PYTHON_VERSION }}"
runs-on: ubuntu-latest
Expand Down

0 comments on commit 624eaef

Please sign in to comment.