File tree Expand file tree Collapse file tree 2 files changed +40
-3
lines changed Expand file tree Collapse file tree 2 files changed +40
-3
lines changed Original file line number Diff line number Diff line change @@ -188,8 +188,10 @@ jobs:
188188 retry_on : any
189189 command : |
190190 . $CONDA/etc/profile.d/conda.sh
191- conda activate ${{ env.TEST_ENV_NAME }}
192- pytest -ra --pyargs ${{ env.PACKAGE_NAME }}.tests
191+ . $CONDA/etc/profile.d/mamba.sh
192+ mamba activate ${{ env.TEST_ENV_NAME }}
193+
194+ python -m pytest -ra --pyargs ${{ env.PACKAGE_NAME }}.tests
193195
194196 test_windows :
195197 name : Test ['windows-2019', python='${{ matrix.python }}']
@@ -323,7 +325,7 @@ jobs:
323325 retry_on : any
324326 command : >-
325327 mamba activate ${{ env.TEST_ENV_NAME }}
326- & pytest -ra --pyargs ${{ env.PACKAGE_NAME }}.tests
328+ & python -m pytest -ra --pyargs ${{ env.PACKAGE_NAME }}.tests
327329
328330 upload :
329331 name : Upload ['${{ matrix.os }}', python='${{ matrix.python }}']
Original file line number Diff line number Diff line change 1515 PACKAGE_NAME : dpnp
1616 CHANNELS : ' -c dppy/label/dev -c https://software.repos.intel.com/python/conda/ -c conda-forge --override-channels'
1717 TEST_ENV_NAME : test
18+ RERUN_TESTS_ON_FAILURE : ' true'
19+ RUN_TESTS_MAX_ATTEMPTS : 2
1820
1921jobs :
2022 test :
8284 python -c "import dpnp; print(dpnp.__version__)"
8385
8486 - name : Run tests
87+ if : env.RERUN_TESTS_ON_FAILURE != 'true'
8588 run : |
8689 python -m pytest -ra --pyargs ${{ env.PACKAGE_NAME }}.tests
8790 env :
8891 SYCL_CACHE_PERSISTENT : 1
92+
93+ - name : ReRun tests on Linux
94+ if : env.RERUN_TESTS_ON_FAILURE == 'true' && matrix.runner != 'windows-2019'
95+ id : run_tests_linux
96+ uses : nick-fields/retry@7152eba30c6575329ac0576536151aca5a72780e # v3.0.0
97+ with :
98+ timeout_minutes : 10
99+ max_attempts : ${{ env.RUN_TESTS_MAX_ATTEMPTS }}
100+ retry_on : any
101+ command : |
102+ . $CONDA/etc/profile.d/conda.sh
103+ . $CONDA/etc/profile.d/mamba.sh
104+ mamba activate ${{ env.TEST_ENV_NAME }}
105+
106+ echo "SYCL_CACHE_PERSISTENT=$SYCL_CACHE_PERSISTENT"
107+
108+ python -m pytest -ra --pyargs ${{ env.PACKAGE_NAME }}.tests
109+ env :
110+ SYCL_CACHE_PERSISTENT : 1
111+
112+ - name : ReRun tests on Windows
113+ if : env.RERUN_TESTS_ON_FAILURE == 'true' && matrix.runner == 'windows-2019'
114+ id : run_tests_win
115+ uses : nick-fields/retry@7152eba30c6575329ac0576536151aca5a72780e # v3.0.0
116+ with :
117+ timeout_minutes : 15
118+ max_attempts : ${{ env.RUN_TESTS_MAX_ATTEMPTS }}
119+ retry_on : any
120+ command : |
121+ python -m pytest -ra --pyargs ${{ env.PACKAGE_NAME }}.tests
122+ env :
123+ SYCL_CACHE_PERSISTENT : 1
You can’t perform that action at this time.
0 commit comments