Skip to content

Commit d2c19c8

Browse files
committed
TST: Set the testing data home environment variable in notebook CI
Set the testing data home environment variable in notebook CI: download the `OpenNeuro` data to the path specified by `TEST_DATA_HOME` environment variable. Streamline setting rest of the relevant environment varibles with the main CI workflow file. Take advantage of the commit to: - Quote the OS version used in the notebook running job for the sake of consistency. - Specify the origin of the data in the `OpenNeuro` data download step. - Specify the path of the script to download the `OpenNeuro` data relative to the GitHub workspace.
1 parent 5f32265 commit d2c19c8

File tree

1 file changed

+10
-5
lines changed

1 file changed

+10
-5
lines changed

.github/workflows/notebooks.yml

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,13 @@ defaults:
1010
run:
1111
shell: bash
1212

13+
# Force tox and pytest to use color
14+
env:
15+
FORCE_COLOR: true
16+
TEST_DATA_HOME: /home/runner/nifreeze-tests/
17+
NIFREEZE_WERRORS: 1
18+
TEST_DATA_REPO: https://gin.g-node.org/nipreps-data/tests-nifreeze
19+
1320
concurrency:
1421
group: ${{ github.workflow }}-${{ github.ref }}
1522
cancel-in-progress: true
@@ -19,7 +26,7 @@ permissions:
1926

2027
jobs:
2128
run-notebooks:
22-
runs-on: ubuntu-latest
29+
runs-on: 'ubuntu-latest'
2330

2431
strategy:
2532
matrix:
@@ -57,11 +64,9 @@ jobs:
5764
python -m pip install --upgrade pip
5865
pip install tox
5966
60-
- name: Download data
67+
- name: Download data from OpenNeuro
6168
run: |
62-
DATA_PATH="${{ env.TEST_DATA_HOME || github.workspace }}/nifreeze-tests"
63-
mkdir -p "$DATA_PATH"
64-
scripts/fetch_fmri_nb_openneuro_data.sh "$DATA_PATH"
69+
${{ github.workspace }}/scripts/fetch_fmri_nb_openneuro_data.sh "${TEST_DATA_HOME}"
6570
6671
- name: Run notebooks with tox
6772
run: tox -e notebooks

0 commit comments

Comments
 (0)