|
1 | 1 | # This workflow will install Python dependencies, run tests and lint with a single version of Python |
2 | 2 | # For more information see: https://help.github.com/actions/language-and-framework-guides/using-python-with-github-actions |
3 | 3 |
|
4 | | -name: Simvue Client (Ubuntu) |
| 4 | +name: Simvue Python API (Ubuntu) |
5 | 5 |
|
6 | 6 | on: |
7 | 7 | push: |
|
10 | 10 | branches: ["main", "dev", "hotfix/update-ci"] |
11 | 11 | workflow_dispatch: |
12 | 12 |
|
13 | | -permissions: |
14 | | - contents: read |
15 | | - |
16 | 13 | concurrency: |
17 | 14 | group: ${{ github.workflow }}-${{ github.ref }} |
18 | 15 | cancel-in-progress: true |
19 | 16 |
|
20 | 17 | jobs: |
21 | | - object_retrieval: |
22 | | - runs-on: ubuntu-latest |
23 | | - timeout-minutes: 30 |
24 | | - steps: |
25 | | - - uses: actions/checkout@v7 |
26 | | - - name: Set up Python 3.14 |
27 | | - uses: actions/setup-python@v7 |
28 | | - with: |
29 | | - python-version: "3.14" |
30 | | - - name: Install dependencies |
31 | | - run: | |
32 | | - python -m pip install poetry |
33 | | - poetry self add poetry-plugin-export |
34 | | - poetry export -f requirements.txt --with dev -o requirements.txt --all-extras |
35 | | - python -m pip install torch --index-url https://download.pytorch.org/whl/cpu || true |
36 | | - python -m pip install -r requirements.txt |
37 | | - python -m pip install . |
38 | | - - name: Test with pytest |
39 | | - env: |
40 | | - SIMVUE_URL: ${{ secrets.SIMVUE_URL }} |
41 | | - SIMVUE_TOKEN: ${{ secrets.SIMVUE_TOKEN }} |
42 | | - run: >- |
43 | | - python -m pytest -x -m object_retrieval -c /dev/null -p no:warnings -n |
44 | | - 8 -v -o cache_dir=${GITHUB_WORKSPACE}/.pytest-cache |
45 | | - object_removal: |
46 | | - runs-on: ubuntu-latest |
47 | | - timeout-minutes: 30 |
48 | | - steps: |
49 | | - - uses: actions/checkout@v7 |
50 | | - - name: Set up Python 3.14 |
51 | | - uses: actions/setup-python@v7 |
52 | | - with: |
53 | | - python-version: "3.14" |
54 | | - - name: Install dependencies |
55 | | - run: | |
56 | | - python -m pip install poetry |
57 | | - poetry self add poetry-plugin-export |
58 | | - poetry export -f requirements.txt --with dev -o requirements.txt --all-extras |
59 | | - python -m pip install torch --index-url https://download.pytorch.org/whl/cpu || true |
60 | | - python -m pip install -r requirements.txt |
61 | | - python -m pip install . |
62 | | - - name: Test with pytest |
63 | | - env: |
64 | | - SIMVUE_URL: ${{ secrets.SIMVUE_URL }} |
65 | | - SIMVUE_TOKEN: ${{ secrets.SIMVUE_TOKEN }} |
66 | | - run: >- |
67 | | - python -m pytest -x -m object_removal -c /dev/null -p no:warnings -n 8 |
68 | | - -v -o cache_dir=${GITHUB_WORKSPACE}/.pytest-cache |
69 | | - dispatch_tests: |
70 | | - runs-on: ubuntu-latest |
71 | | - timeout-minutes: 30 |
72 | | - steps: |
73 | | - - uses: actions/checkout@v7 |
74 | | - - name: Set up Python 3.14 |
75 | | - uses: actions/setup-python@v7 |
76 | | - with: |
77 | | - python-version: "3.14" |
78 | | - - name: Install dependencies |
79 | | - run: | |
80 | | - python -m pip install poetry |
81 | | - poetry self add poetry-plugin-export |
82 | | - poetry export -f requirements.txt --with dev -o requirements.txt --all-extras |
83 | | - python -m pip install -r requirements.txt |
84 | | - python -m pip install . |
85 | | - - name: Test with pytest |
86 | | - env: |
87 | | - SIMVUE_URL: ${{ secrets.SIMVUE_URL }} |
88 | | - SIMVUE_TOKEN: ${{ secrets.SIMVUE_TOKEN }} |
89 | | - run: >- |
90 | | - python -m pytest -x -m dispatch -c /dev/null -p no:warnings -n 8 -v -o |
91 | | - cache_dir=${GITHUB_WORKSPACE}/.pytest-cache |
92 | | - run_tests_online: |
93 | | - runs-on: ubuntu-latest |
94 | | - timeout-minutes: 30 |
95 | | - steps: |
96 | | - - uses: actions/checkout@v7 |
97 | | - - name: Set up Python 3.14 |
98 | | - uses: actions/setup-python@v7 |
99 | | - with: |
100 | | - python-version: "3.14" |
101 | | - - name: Install dependencies |
102 | | - run: | |
103 | | - python -m pip install poetry |
104 | | - poetry self add poetry-plugin-export |
105 | | - poetry export -f requirements.txt --with dev -o requirements.txt --all-extras |
106 | | - python -m pip install torch --index-url https://download.pytorch.org/whl/cpu || true |
107 | | - python -m pip install -r requirements.txt |
108 | | - python -m pip install . |
109 | | - - name: Test with pytest |
110 | | - env: |
111 | | - SIMVUE_URL: ${{ secrets.SIMVUE_URL }} |
112 | | - SIMVUE_TOKEN: ${{ secrets.SIMVUE_TOKEN }} |
113 | | - run: >- |
114 | | - python -m pytest -x -m "online and not api" -c /dev/null -p |
115 | | - no:warnings -n 8 -v -o cache_dir=${GITHUB_WORKSPACE}/.pytest-cache |
116 | | - run_tests_offline: |
117 | | - runs-on: ubuntu-latest |
118 | | - timeout-minutes: 30 |
119 | | - steps: |
120 | | - - uses: actions/checkout@v7 |
121 | | - - name: Set up Python 3.14 |
122 | | - uses: actions/setup-python@v7 |
123 | | - with: |
124 | | - python-version: "3.14" |
125 | | - - name: Install dependencies |
126 | | - run: | |
127 | | - python -m pip install poetry |
128 | | - poetry self add poetry-plugin-export |
129 | | - poetry export -f requirements.txt --with dev -o requirements.txt --all-extras |
130 | | - python -m pip install torch --index-url https://download.pytorch.org/whl/cpu || true |
131 | | - python -m pip install -r requirements.txt |
132 | | - python -m pip install . |
133 | | - - name: Test with pytest |
134 | | - env: |
135 | | - SIMVUE_URL: "${{ secrets.SIMVUE_URL }}" |
136 | | - SIMVUE_TOKEN: ${{ secrets.SIMVUE_TOKEN }} |
137 | | - run: >- |
138 | | - python -m pytest -x -m "(offline and not api) or cli" -c /dev/null -p |
139 | | - no:warnings -n 0 -v -o cache_dir=${GITHUB_WORKSPACE}/.pytest-cache |
140 | | - config_tests: |
141 | | - runs-on: ubuntu-latest |
142 | | - timeout-minutes: 30 |
143 | | - steps: |
144 | | - - uses: actions/checkout@v7 |
145 | | - - name: Set up Python 3.14 |
146 | | - uses: actions/setup-python@v7 |
147 | | - with: |
148 | | - python-version: "3.14" |
149 | | - - name: Install dependencies |
150 | | - run: | |
151 | | - python -m pip install poetry |
152 | | - poetry self add poetry-plugin-export |
153 | | - poetry export -f requirements.txt --with dev -o requirements.txt --all-extras |
154 | | - python -m pip install -r requirements.txt |
155 | | - python -m pip install . |
156 | | - - name: Test with pytest |
157 | | - env: |
158 | | - SIMVUE_URL: ${{ secrets.SIMVUE_URL }} |
159 | | - SIMVUE_TOKEN: ${{ secrets.SIMVUE_TOKEN }} |
160 | | - run: >- |
161 | | - python -m pytest -x -m config -c /dev/null -p no:warnings -n 8 -v -o |
162 | | - cache_dir=${GITHUB_WORKSPACE}/.pytest-cache |
163 | | - scenario_tests: |
164 | | - runs-on: ubuntu-latest |
165 | | - timeout-minutes: 30 |
166 | | - steps: |
167 | | - - uses: actions/checkout@v7 |
168 | | - - name: Set up Python 3.14 |
169 | | - uses: actions/setup-python@v7 |
170 | | - with: |
171 | | - python-version: "3.14" |
172 | | - - name: Install dependencies |
173 | | - run: | |
174 | | - python -m pip install poetry |
175 | | - poetry self add poetry-plugin-export |
176 | | - poetry export -f requirements.txt --with dev -o requirements.txt --all-extras |
177 | | - python -m pip install -r requirements.txt |
178 | | - python -m pip install . |
179 | | - - name: Test with pytest |
180 | | - env: |
181 | | - SIMVUE_URL: ${{ secrets.SIMVUE_URL }} |
182 | | - SIMVUE_TOKEN: ${{ secrets.SIMVUE_TOKEN }} |
183 | | - run: >- |
184 | | - python -m pytest -x -m "scenario and not run" -c /dev/null -p |
185 | | - no:warnings -n 0 -v -o cache_dir=${GITHUB_WORKSPACE}/.pytest-cache |
186 | | - executor_tests: |
187 | | - runs-on: ubuntu-latest |
188 | | - timeout-minutes: 30 |
189 | | - steps: |
190 | | - - uses: actions/checkout@v7 |
191 | | - - name: Set up Python 3.14 |
192 | | - uses: actions/setup-python@v7 |
193 | | - with: |
194 | | - python-version: "3.14" |
195 | | - - name: Install dependencies |
196 | | - run: | |
197 | | - python -m pip install poetry |
198 | | - poetry self add poetry-plugin-export |
199 | | - poetry export -f requirements.txt --with dev -o requirements.txt --all-extras |
200 | | - python -m pip install -r requirements.txt |
201 | | - python -m pip install . |
202 | | - - name: Test with pytest |
203 | | - env: |
204 | | - SIMVUE_URL: ${{ secrets.SIMVUE_URL }} |
205 | | - SIMVUE_TOKEN: ${{ secrets.SIMVUE_TOKEN }} |
206 | | - run: >- |
207 | | - python -m pytest -x -m executor -c /dev/null -p no:warnings -n 0 -v -o |
208 | | - cache_dir=${GITHUB_WORKSPACE}/.pytest-cache |
209 | | - api_tests: |
210 | | - runs-on: ubuntu-latest |
211 | | - timeout-minutes: 30 |
212 | | - steps: |
213 | | - - uses: actions/checkout@v7 |
214 | | - - name: Set up Python 3.14 |
215 | | - uses: actions/setup-python@v7 |
216 | | - with: |
217 | | - python-version: "3.14" |
218 | | - - name: Install dependencies |
219 | | - run: | |
220 | | - python -m pip install poetry |
221 | | - poetry self add poetry-plugin-export |
222 | | - poetry export -f requirements.txt --with dev -o requirements.txt --all-extras |
223 | | - python -m pip install -r requirements.txt |
224 | | - python -m pip install . |
225 | | - - name: Test with pytest |
226 | | - env: |
227 | | - SIMVUE_URL: ${{ secrets.SIMVUE_URL }} |
228 | | - SIMVUE_TOKEN: ${{ secrets.SIMVUE_TOKEN }} |
229 | | - run: >- |
230 | | - python -m pytest -x -m api -c /dev/null -p no:warnings -n 0 -v -o |
231 | | - cache_dir=${GITHUB_WORKSPACE}/.pytest-cache |
232 | | - local_tests: |
233 | | - runs-on: ubuntu-latest |
234 | | - timeout-minutes: 30 |
235 | | - steps: |
236 | | - - uses: actions/checkout@v7 |
237 | | - - name: Set up Python 3.14 |
238 | | - uses: actions/setup-python@v7 |
239 | | - with: |
240 | | - python-version: "3.14" |
241 | | - - name: Install dependencies |
242 | | - run: | |
243 | | - python -m pip install poetry |
244 | | - poetry self add poetry-plugin-export |
245 | | - poetry export -f requirements.txt --with dev -o requirements.txt --all-extras |
246 | | - python -m pip install -r requirements.txt |
247 | | - python -m pip install . |
248 | | - - name: Test with pytest |
249 | | - env: |
250 | | - SIMVUE_URL: ${{ secrets.SIMVUE_URL }} |
251 | | - SIMVUE_TOKEN: ${{ secrets.SIMVUE_TOKEN }} |
252 | | - run: >- |
253 | | - python -m pytest -x -m local -c /dev/null -p no:warnings -n 8 -v -o |
254 | | - cache_dir=${GITHUB_WORKSPACE}/.pytest-cache |
| 18 | + test_suite: |
| 19 | + name: Test Suite |
| 20 | + uses: ./.github/workflows/common.yml |
| 21 | + with: |
| 22 | + platform: ubuntu-latest |
| 23 | + python-version: "3.14" |
| 24 | + secrets: inherit |
0 commit comments