build #76
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: build | |
on: | |
push: | |
paths-ignore: | |
- doc/** | |
- .gitignore | |
- LICENSE.txt | |
- README.md | |
workflow_dispatch: | |
schedule: | |
- cron: '0 0 * * 0' | |
jobs: | |
install-and-test: | |
name: ${{ matrix.os }} | |
runs-on: ${{ matrix.os }} | |
strategy: | |
matrix: | |
os: [macos-latest, ubuntu-latest, windows-latest] | |
defaults: | |
run: | |
shell: bash -l {0} | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Set up conda environment | |
uses: conda-incubator/setup-miniconda@v2 | |
with: | |
activate-environment: infresnel | |
environment-file: environment.yml | |
miniforge-variant: Mambaforge | |
use-mamba: true | |
- name: Install development packages | |
run: pip install --requirement requirements.txt | |
- name: Check formatting | |
run: | | |
black --skip-string-normalization --check . | |
isort --conda-env infresnel --profile black --check-only . | |
- name: Run tests | |
run: pytest --capture=no |