add dim_reduce to aggregates, refactor patch utils (#456) #291
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
# Calculates new coverage for the base branch and uploads to codecov | |
name: Coverage | |
on: | |
push: | |
branches: | |
- master | |
jobs: | |
calc_coverage: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: "get tags" | |
run: | | |
git fetch --tags --force # Retrieve annotated tags. | |
- uses: mamba-org/setup-micromamba@v1 | |
with: | |
micromamba-version: '1.5.8-0' # versions: https://github.com/mamba-org/micromamba-releases | |
environment-file: environment.yml | |
init-shell: >- | |
bash | |
powershell | |
cache-environment: true | |
post-cleanup: 'all' | |
# Not sure why this is needed but it appears to be the case | |
- name: fix env | |
shell: bash -l {0} | |
run: | | |
micromamba shell init --shell bash --root-prefix=~/micromamba | |
eval "$(micromamba shell hook --shell bash)" | |
micromamba activate dascore | |
- name: install dascore | |
shell: bash -l {0} | |
run: | | |
python -m pip install -e .[test] | |
- name: run test suite | |
shell: bash -l {0} | |
run: | | |
pytest -s --cov dascore --cov-report=xml | |
- uses: codecov/codecov-action@v4 | |
with: | |
fail_ci_if_error: true | |
files: ./coverage.xml | |
flags: unittests # optional | |
name: master_tests # optional | |
token: ${{ secrets.CODECOV_TOKEN }} # required |