-
Notifications
You must be signed in to change notification settings - Fork 351
109 lines (91 loc) · 2.95 KB
/
Copy pathtest-python-win.yml
File metadata and controls
109 lines (91 loc) · 2.95 KB
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
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
name: test-python-win
on: [push, pull_request]
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
build:
runs-on: ${{ matrix.os }}
strategy:
matrix:
# os: [self-hosted]
os: [windows-2022]
python: ["3.10", "3.14"]
steps:
- uses: actions/checkout@v6
- name: Install correct python version
uses: actions/setup-python@v6
with:
python-version: ${{ matrix.python }}
- name: Install pytest
run: python -m pip install pytest
- name: Test python install
run: |
python -m pip install .
pytest ./highspy
- name: Test Python Examples
run: |
python ./examples/call_highs_from_python_highspy.py
python ./examples/call_highs_from_python_mps.py
python ./examples/minimal.py
build_hipo:
runs-on: ${{ matrix.os }}
strategy:
matrix:
# os: [self-hosted]
os: [windows-2022]
python: [3.12]
steps:
- uses: actions/checkout@v6
- name: Install correct python version
uses: actions/setup-python@v6
with:
python-version: ${{ matrix.python }}
- name: Install test dependencies
run: python -m pip install pytest
- name: Test python install
run: |
python -m pip install ./highspy-extras
python -m pip install .
pytest
pytest check/test_highspy_hipo.py
- name: Test Python Examples
run: |
python ./examples/call_highs_from_python_highspy.py
python ./examples/call_highs_from_python_mps.py
python ./examples/minimal.py
build_hipo_local:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [windows-2022]
python: [3.12]
steps:
- uses: actions/checkout@v6
- name: Install correct python version
uses: actions/setup-python@v6
with:
python-version: ${{ matrix.python }}
- name: Install test dependencies
run: python -m pip install pytest
- name: Install OpenBLAS
run: vcpkg install openblas[threads]:x64-windows-static
- name: Install highspy-extras
run: |
$blas = "$env:VCPKG_INSTALLATION_ROOT/installed/x64-windows-static/lib/openblas.lib"
Write-Host "BLAS path: $blas"
python -m pip install ./highspy-extras `
--config-settings=cmake.define.BUILD_OPENBLAS=OFF `
"--config-settings=cmake.define.BLAS_LIBRARIES=$blas"
- name: Install highspy
run: |
python -m pip install .
python -c "import highspy; print(dir(highspy))"
- name: Test python install
run: |
pytest highspy/tests check/test_highspy_hipo.py
- name: Test Python Examples
run: |
python ./examples/call_highs_from_python_highspy.py
python ./examples/call_highs_from_python_mps.py
python ./examples/minimal.py