Enh/compute_subject_gm_mask #3374
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
name: Run Tests | |
on: | |
push: | |
paths: | |
- 'junifer/**' | |
- '.github/workflows/**' | |
pull_request: | |
paths: | |
- 'junifer/**' | |
- '.github/workflows/**' | |
jobs: | |
run-tests: | |
runs-on: ubuntu-latest | |
# Use custom docs CI image | |
container: ghcr.io/juaml/junifer-ci:main | |
strategy: | |
fail-fast: false | |
matrix: | |
python-version: ['3.9', '3.10', '3.11', '3.12', '3.13'] | |
steps: | |
- name: Check ANTs | |
run: | | |
echo "Using ANTs : $(antsRegistration --version)" | |
- name: Check AFNI | |
run: | | |
echo "Using AFNI : $(afni --version)" | |
- name: Check FSL | |
run: | | |
echo "Using FSL : $(flirt -version)" | |
- name: Install system dependencies | |
run: | | |
# actions/checkout fails to identify Git as it's not in the CI image | |
apt-get -qq update && \ | |
apt-get -qq install -y \ | |
git \ | |
git-annex \ | |
make \ | |
jq | |
# Copy xfms directory | |
mkdir -p $HOME/junifer/data/xfms && \ | |
cp -ar /root/junifer/data/xfms/. $HOME/junifer/data/xfms/ | |
- name: Checkout repository | |
uses: actions/checkout@v4 | |
with: | |
submodules: true | |
- name: Set up Python ${{ matrix.python-version }} | |
uses: actions/setup-python@v5 | |
with: | |
python-version: ${{ matrix.python-version }} | |
- name: Install Python dependencies | |
run: | | |
python -m pip install --upgrade pip setuptools wheel | |
python -m pip install tox tox-gh-actions | |
- name: Configure Git for DataLad | |
run: | | |
git config --global user.email "[email protected]" | |
git config --global user.name "GitHub Runner" | |
- name: Test with tox | |
run: | | |
# https://github.com/actions/checkout/issues/1169#issuecomment-2291682583 | |
git config --system --add safe.directory $(pwd) | |
tox | |
- name: Upload coverage to Codecov | |
uses: codecov/codecov-action@v4 | |
with: | |
token: ${{ secrets.CODECOV_TOKEN }} | |
fail_ci_if_error: true | |
flags: junifer | |
if: success() && matrix.python-version == 3.12 |