-
Notifications
You must be signed in to change notification settings - Fork 0
63 lines (63 loc) · 2.11 KB
/
windows.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
name: Test on Windows
on:
push:
workflow_dispatch:
# workflow_run:
# workflows: [ CI ]
# types: [ completed ]
env:
PRIMARY_PYTHON_VERSION: '3.12'
jobs:
test:
runs-on: windows-latest
# if: ${{ github.event.workflow_run.conclusion == 'success' }}
timeout-minutes: 25
steps:
- name: Setup Python
uses: actions/setup-python@v5
# Windows minutes cost 2x what Linux does, so testing multiple Python versions would be quite costly
with:
python-version: ${{ env.PRIMARY_PYTHON_VERSION }}
- name: Print Python version
run: python -V
- name: Checkout
uses: actions/checkout@v4
- name: Load pip cache
uses: actions/cache@v4
with:
path: .pip
key: pip-${{ runner.os }}-${{ hashFiles('requirements.txt') }}
restore-keys: |
pip-${{ runner.os }}-
pip-
- name: Install requirements
# Todo: fix NumbaLSODA installation on Windows
# Currently the requirements are specified manually to skip NumbaLSODA
run: |
pip --cache-dir=.pip install --upgrade pip
pip --cache-dir=.pip install --upgrade wheel
pip --cache-dir=.pip install -r requirements.txt -r requirements-dev.txt
- name: Print Numba sysinfo
run: python -m numba --sysinfo | tee numba-sysinfo.txt
- name: Generate reference data
run: python3 pttools/bubble/fluid_reference.py
env:
PYTHONPATH: .
- name: Run tests
# Failures may not get processed properly, as pipefail is not supported on Windows.
# set -o pipefail
run: |
pytest | tee test-output.txt
coverage json
- name: Upload results
uses: actions/upload-artifact@v4
with:
name: Test results with Numba
path: |
coverage.xml
coverage.json
htmlcov
numba-sysinfo.txt
test-output.txt
test-results
if-no-files-found: error