Test mac on self-hosted runner #15
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: mac-ci | |
on: [push, pull_request] | |
jobs: | |
tests: | |
runs-on: [self-hosted, macOS] | |
if: github.repository == 'stfc/janus-core' | |
timeout-minutes: 30 | |
strategy: | |
matrix: | |
python-version: ['3.9','3.10','3.11','3.12'] | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Install uv | |
uses: astral-sh/setup-uv@v4 | |
with: | |
version: "0.5.7" | |
python-version: ${{ matrix.python-version }} | |
- name: Install dependencies | |
run: uv sync --all-extras | |
- name: Run test suite | |
env: | |
# show timings of tests | |
PYTEST_ADDOPTS: "--durations=0" | |
run: uv run pytest --run-extra-mlips --cov janus_core --cov-append . | |
- name: Set Path | |
run: | | |
source ~/.zshrc | |
echo "PATH=$PATH" >> $GITHUB_ENV | |
- name: Report coverage to Coveralls | |
uses: coverallsapp/github-action@v2 | |
with: | |
parallel: true | |
flag-name: run-${{ matrix.python-version }} | |
file: coverage.xml | |
base-path: janus_core | |
coverage: | |
needs: tests | |
runs-on: self-hosted | |
steps: | |
- name: Close parallel build | |
uses: coverallsapp/github-action@v2 | |
with: | |
parallel-finished: true |