-
Notifications
You must be signed in to change notification settings - Fork 9
49 lines (43 loc) · 1.41 KB
/
test.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
name: CI
on:
push:
branches:
- '**'
tags-ignore:
- '**'
pull_request:
branches:
- '**'
jobs:
test:
runs-on: ubuntu-latest
defaults:
run:
shell: bash -l {0}
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
strategy:
matrix:
notebook: [3dep, 3dhp, aridity, columbia, cross_section, dam_impact, daymet, flood_peak, geoconnex, gridmet, hwms, hymod_calibration, ndvi, nhd_navigation, nhdplus, nid, nlcd, nldas, noaa, nwis, pet_validation, pygeoapi, rem, ridges, signatures, soil, ssebop, things, us_coasts, water_quality, webservices]
steps:
- uses: actions/checkout@v4
- name: Set environment variables
run: |-
echo "TODAY=$(date +'%Y-%m-%d')" >> $GITHUB_ENV
echo "CONDA_ENV_FILE=environment.yml" >> $GITHUB_ENV
- name: Setup micromamba
uses: mamba-org/setup-micromamba@v1
with:
environment-file: ${{ env.CONDA_ENV_FILE }}
environment-name: binder
cache-environment: true
cache-environment-key: ${{env.TODAY}}-${{hashFiles(env.CONDA_ENV_FILE)}}
- name: Install nbmake
run: micromamba install -y pytest nbmake
- name: Version info
run: |-
python -c "import pygeohydro; pygeohydro.show_versions()"
- name: Run nbmake
run: |-
python -m pytest --nbmake notebooks/${{ matrix.notebook }}.ipynb