Skip to content

[pre-commit.ci] pre-commit autoupdate #202

[pre-commit.ci] pre-commit autoupdate

[pre-commit.ci] pre-commit autoupdate #202

Workflow file for this run

name: CI
on:
workflow_dispatch:
push:
branches:
- "main"
pull_request:
branches:
- "*"
schedule:
- cron: "0 13 * * 1"
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
build:
name: Build (${{ matrix.python-version }} | ${{ matrix.os }})
if: github.repository == 'ocean-transport/scale-aware-air-sea'
runs-on: ${{ matrix.os }}
defaults:
run:
shell: bash -l {0}
strategy:
fail-fast: false
matrix:
os: ["ubuntu-latest"]
python-version: ["3.9", "3.10"]
steps:
- uses: actions/checkout@v3
- name: Create conda environment
uses: mamba-org/provision-with-micromamba@main
with:
cache-downloads: true
cache-env: true
micromamba-version: 'latest'
environment-file: ci/environment.yaml
extra-specs: |
python=${{ matrix.python-version }}
- name: Install SAAS
run: |
python -m pip install -e . --no-deps
conda list
- name: Run Tests
run: |
pytest --cov=./ --cov-report=xml
- name: Upload code coverage to Codecov
uses: codecov/[email protected]
with:
file: ./coverage.xml
flags: unittests
env_vars: OS,PYTHON
name: codecov-umbrella
fail_ci_if_error: false