Skip to content

Commit 62a450f

Browse files
committed
Cache RosettaSciIO test data
1 parent 6f80192 commit 62a450f

File tree

1 file changed

+16
-0
lines changed

1 file changed

+16
-0
lines changed

.github/workflows/release.yml

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -293,6 +293,22 @@ jobs:
293293
conda activate "${{ env.install_dir }}"
294294
mamba install ${{ env.TEST_DEPS }}
295295
296+
- name: Get rosettasciio tests data location
297+
run: |
298+
python -c "from rsciio.tests import registry; print(f'ROSETTASCIIO_TEST_DATA={str(registry.TESTS_PATH / \"data\") }')" >> $GITHUB_ENV
299+
300+
- name: Cache rosettasciio data
301+
uses: actions/cache@v4
302+
env:
303+
# Increase this value to reset cache
304+
CACHE_NUMBER: 0
305+
with:
306+
path: ${{ env.ROSETTASCIIO_TEST_DATA }}
307+
key:
308+
RosettaSciIO-test_data-${{ env.CACHE_NUMBER }}
309+
restore-keys: |
310+
RosettaSciIO-test_data-${{ env.CACHE_NUMBER }}
311+
296312
- if: always()
297313
name: Test new distribution (HyperSpyUI)
298314
run: |

0 commit comments

Comments
 (0)