-
Notifications
You must be signed in to change notification settings - Fork 1
98 lines (82 loc) · 2.58 KB
/
Copy pathtests.yaml
File metadata and controls
98 lines (82 loc) · 2.58 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
name: Tests
on:
push:
pull_request:
workflow_dispatch:
jobs:
Core:
name: ${{ matrix.os }} - ${{ matrix.config_name }} - Qt ${{ matrix.qt_version }}
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, windows-latest, macos-latest]
config_name: [Widgets, QML]
qt_version: [6.10.1, 6.10.2]
include:
- config_name: "Widgets"
cmake_flags: "-DSIMPLE_MAP_VIEW_BUILD_TESTS=ON"
build_type: "Debug"
- config_name: "QML"
cmake_flags: "-DSIMPLE_MAP_VIEW_BUILD_QML=ON -DSIMPLE_MAP_VIEW_BUILD_TESTS=ON"
build_type: "Debug"
steps:
- name: Checkout
uses: actions/checkout@v6
- name: Setup Qt Environment
uses: ./.github/actions/setup-qt-env
with:
qt_version: ${{ matrix.qt_version }}
- name: Configure CMake
shell: bash
run: |
mkdir build
cd build
cmake .. ${{ matrix.cmake_flags }} -DCMAKE_BUILD_TYPE=${{ matrix.build_type }}
- name: Build
shell: bash
working-directory: build
run: |
cmake --build . --config ${{ matrix.build_type }}
- name: Run (Linux)
if: runner.os == 'Linux'
working-directory: build
run: xvfb-run ctest --output-on-failure
- name: Run (Windows / macOS)
if: runner.os != 'Linux'
shell: bash
working-directory: build
run: ctest -C ${{ matrix.build_type }} --output-on-failure
Python:
name: ${{ matrix.os }} - Qt ${{ matrix.qt_version }} - Python ${{ matrix.python_version }}
needs: Core
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, windows-latest]
python_version: ['3.10', '3.11', '3.12', '3.13']
qt_version: [6.10.1, 6.10.2]
steps:
- name: Checkout
uses: actions/checkout@v6
- name: Setup Qt Environment
uses: ./.github/actions/setup-qt-env
with:
qt_version: ${{ matrix.qt_version }}
- name: Setup Python Environment
uses: ./.github/actions/setup-python-env
with:
python_version: ${{ matrix.python_version }}
qt_version: ${{ matrix.qt_version }}
- name: Install Bindings
shell: bash
env:
PYTHONIOENCODING: utf-8
run: pip install .
- name: Run (Linux)
if: runner.os == 'Linux'
run: xvfb-run pytest
- name: Run (Windows)
if: runner.os != 'Linux'
run: pytest