99 MODULE_NAME : mkl_umath
1010
1111jobs :
12- build :
12+ build_linux :
1313 runs-on : ubuntu-latest
1414 strategy :
1515 matrix :
6060 name : ${{ env.PACKAGE_NAME }} ${{ runner.os }} Python ${{ matrix.python }}
6161 path : ${{ env.CONDA_BLD }}/${{ env.PACKAGE_NAME }}-*.tar.bz2
6262
63- test :
64- needs : build
63+ test_linux :
64+ needs : build_linux
6565 runs-on : ${{ matrix.runner }}
6666
6767 strategy :
@@ -205,18 +205,24 @@ jobs:
205205
206206 - uses : conda-incubator/setup-miniconda@v3
207207 with :
208- auto-update-conda : true
209- conda-build-version : ' *'
210208 miniforge-variant : Miniforge3
211209 miniforge-version : latest
212210 activate-environment : mkl_umath_test
213- channels : conda-forge
211+ channels : conda-forge,nodefaults
214212 python-version : ${{ matrix.python }}
215213
214+ - name : Remove defaults channel
215+ run : conda config --remove channels defaults
216+
217+ - name : Install conda-index
218+ run : |
219+ conda install -n base conda-index
220+
216221 - name : Create conda channel with the artifact bit
217222 shell : cmd /C CALL {0}
218223 run : |
219224 echo ${{ env.workdir }}
225+ mkdir ${{ env.workdir }}\channel
220226 mkdir ${{ env.workdir }}\channel\win-64
221227 move ${{ env.PACKAGE_NAME }}-*.tar.bz2 ${{ env.workdir }}\channel\win-64
222228 dir ${{ env.workdir }}\channel\win-64
@@ -230,16 +236,20 @@ jobs:
230236 shell : cmd /C CALL {0}
231237 run : |
232238 conda search ${{ env.PACKAGE_NAME }} -c ${{ env.workdir }}/channel --override-channels --info --json
239+
233240 - name : Dump mkl_umath version info from created channel into ver.json
234241 shell : cmd /C CALL {0}
235242 run : |
236243 conda search ${{ env.PACKAGE_NAME }} -c ${{ env.workdir }}/channel --override-channels --info --json > ${{ env.workdir }}\ver.json
244+
237245 - name : Output content of workdir
238246 shell : pwsh
239247 run : Get-ChildItem -Path ${{ env.workdir }}
248+
240249 - name : Output content of produced ver.json
241250 shell : pwsh
242251 run : Get-Content -Path ${{ env.workdir }}\ver.json
252+
243253 - name : Collect dependencies
244254 shell : cmd /C CALL {0}
245255 run : |
@@ -251,9 +261,11 @@ jobs:
251261 SET PACKAGE_VERSION=%%F
252262 )
253263 conda install -n mkl_umath_test ${{ env.PACKAGE_NAME }}=%PACKAGE_VERSION% python=${{ matrix.python }} -c ${{ env.workdir }}/channel ${{ env.CHANNELS }} --only-deps --dry-run > lockfile
264+
254265 - name : Display lockfile content
255266 shell : pwsh
256267 run : Get-Content -Path .\lockfile
268+
257269 - name : Cache conda packages
258270 uses : actions/cache@v4
259271 env :
@@ -265,6 +277,7 @@ jobs:
265277 restore-keys : |
266278 ${{ runner.os }}-conda-${{ env.CACHE_NUMBER }}-python-${{ matrix.python }}-
267279 ${{ runner.os }}-conda-${{ env.CACHE_NUMBER }}-
280+
268281 - name : Install mkl_umath
269282 shell : cmd /C CALL {0}
270283 run : |
@@ -278,15 +291,16 @@ jobs:
278291 )
279292 SET "TEST_DEPENDENCIES=pytest pytest-cov"
280293 conda install -n mkl_umath_test ${{ env.PACKAGE_NAME }}=%PACKAGE_VERSION% %TEST_DEPENDENCIES% python=${{ matrix.python }} -c ${{ env.workdir }}/channel ${{ env.CHANNELS }}
294+
281295 - name : Report content of test environment
282296 shell : cmd /C CALL {0}
283297 run : |
284298 conda activate
285299 echo "Value of CONDA enviroment variable was: " %CONDA%
286300 echo "Value of CONDA_PREFIX enviroment variable was: " %CONDA_PREFIX%
287301 conda info && conda list -n mkl_umath_test
302+
288303 - name : Run tests
289304 shell : cmd /C CALL {0}
290305 run : >-
291306 conda activate mkl_umath_test && python -c "import mkl_umath, numpy as np; mkl_umath.use_in_numpy(); np.sin(np.linspace(0, 1, num=10**6));"
292-
0 commit comments