@@ -107,77 +107,68 @@ jobs:
107107 python -c "import fileformats.medimage_afni as m; print(f'{m.__name__} {m.__version__} @ {m.__file__}')"
108108 - name : Test fileformats with pytest
109109 run : |
110- cd ./fileformats
111- pytest -sv --cov fileformats.medimage_afni --cov fileformats.extras.medimage_afni --cov-report xml .
110+ pytest ./related-packages -sv --cov fileformats.medimage_afni --cov fileformats.extras.medimage_afni --cov-report xml .
112111
113112 test :
114113 needs : [nipype-conv, fileformats-test]
115114 runs-on : ubuntu-22.04
116115 strategy :
117116 matrix :
118- python-version : ['3.8'] # '3.11'
117+ python-version : ['3.8', '3.11']
119118 steps :
119+
120120 - name : Removed unnecessary tools to free space
121121 run : |
122122 sudo rm -rf /usr/share/dotnet
123- sudo rm -rf "$AGENT_TOOLSDIRECTORY"
124- - name : Get Download cache Key
125- id : cache-key
126- run : echo "::set-output name=key::afni-linux-ubuntu22_amd64-7.4.1"
127- - name : Cache FreeSurfer
128- uses : actions/cache@v2
129- with :
130- path : $HOME/downloads/afni
131- key : ${{ steps.cache-key.outputs.key }}
132- restore-keys : |
133- afni-linux-ubuntu22_amd64-7.4.1
134- - name : Download FreeSurfer
135- if : steps.cache-key.outputs.key != steps.cache-hit.outputs.key
136- run : |
137- mkdir -p $HOME/downloads/afni
138- curl -s -o $HOME/downloads/afni/afni-linux-ubuntu22_amd64-7.4.1.tar.gz https://surfer.nmr.mgh.harvard.edu/pub/dist/afni/7.4.1/afni-linux-ubuntu22_amd64-7.4.1.tar.gz
139- shell : bash
140- - name : Install Freesurfer
141- env :
142- FREESURFER_LICENCE : ${{ secrets.FREESURFER_LICENCE }}
143- run : |
144- pushd $HOME/downloads/afni
145- tar -zxpf afni-linux-ubuntu22_amd64-7.4.1.tar.gz
146- mv afni $HOME/
147- popd
148- export FREESURFER_HOME=$HOME/afni
149- source $FREESURFER_HOME/SetUpFreeSurfer.sh
150- echo $FREESURFER_LICENCE > $FREESURFER_HOME/license.txt
151- export PATH=$FREESURFER_HOME/bin:$PATH
152- - uses : actions/checkout@v3
123+ sudo rm -rf "$AGENT_TOOLSDIRECTORY"
124+
125+ - name : Checkout repo
126+ uses : actions/checkout@v3
127+
153128 - name : Revert version to most recent tag on upstream update
154129 if : github.event_name == 'repository_dispatch'
155130 run : git checkout $(git tag -l | tail -n 1 | awk -F post '{print $1}')
131+
132+ - name : Install AFNI
133+ run : |
134+ curl -O https://raw.githubusercontent.com/afni/afni/master/src/other_builds/OS_notes.linux_ubuntu_22_64_a_admin.txt
135+ curl -O https://raw.githubusercontent.com/afni/afni/master/src/other_builds/OS_notes.linux_ubuntu_22_64_b_user.tcsh
136+ sudo bash OS_notes.linux_ubuntu_22_64_a_admin.txt 2>&1 | tee o.ubuntu_22_a.txt
137+
156138 - name : Download tasks converted from Nipype
157139 uses : actions/download-artifact@v3
158140 with :
159141 name : converted-nipype
160142 path : pydra/tasks/afni/auto
143+
144+ - name : Show the contents of the auto-generated tasks
145+ run : tree pydra
146+
161147 - name : Strip auto package from gitignore so it is included in package
162148 run : |
163- sed -i '/\/src\/pydra\/tasks\/afni\/auto/d' .gitignore
149+ sed -i '/\/pydra\/tasks\/afni\/auto/d' .gitignore
150+
164151 - name : Set up Python ${{ matrix.python-version }}
165152 uses : actions/setup-python@v4
166153 with :
167154 python-version : ${{ matrix.python-version }}
155+
168156 - name : Install build dependencies
169157 run : |
170158 python -m pip install --upgrade pip
159+
171160 - name : Install task package
172161 run : |
173162 pip install "./related-packages/fileformats" "./related-packages/fileformats-extras" ".[test]"
174163 python -c "import pydra.tasks.afni as m; print(f'{m.__name__} {m.__version__} @ {m.__file__}')"
175164 python -c "import pydra as m; print(f'{m.__name__} {m.__version__} @ {m.__file__}')"
165+
176166 - name : Test with pytest
177167 run : |
178- pytest -sv --doctest-modules ./pydra/tasks/afni \
179- --cov pydra.tasks.afni --cov-report xml
180- - uses : codecov/codecov-action@v3
168+ pytest -sv ./pydra/tasks/afni --cov pydra.tasks.afni --cov-report xml
169+
170+ - name : Upload to CodeCov
171+ uses : codecov/codecov-action@v3
181172 if : ${{ always() }}
182173 with :
183174 files : coverage.xml,./fileformats/coverage.xml
0 commit comments