-
Notifications
You must be signed in to change notification settings - Fork 23
104 lines (91 loc) · 2.44 KB
/
python-bindings.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
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
name: 🐍 • CI
on:
push:
branches: [ 'main' ]
paths:
- 'bindings/pyfiction/**'
- '**/*.py'
- '**/*.hpp'
- '**/*.cpp'
- '**/*.cmake'
- '**/CMakeLists.txt'
- 'libs/**'
- '.github/workflows/python-bindings.yml'
pull_request:
branches: [ 'main' ]
paths:
- 'bindings/pyfiction/**'
- '**/*.py'
- '**/*.hpp'
- '**/*.cpp'
- '**/*.cmake'
- '**/CMakeLists.txt'
- 'libs/**'
- '.github/workflows/python-bindings.yml'
workflow_run:
workflows: [ "pyfiction Docstring Generator" ]
types:
- completed
concurrency:
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
cancel-in-progress: true
defaults:
run:
shell: bash
env:
Z3_VERSION: 4.13.0
ENABLE_Z3: 'ON'
jobs:
build_and_test:
strategy:
matrix:
os: [ ubuntu-22.04, macos-14, windows-2019 ]
python_version: [ '3.8.x', '3.12.x' ]
include:
- os: ubuntu-22.04
z3_platform: linux
architecture: x64
toolset: v142
- os: macos-14
z3_platform: macOS
architecture: arm64
- os: windows-2019
z3_platform: windows
architecture: x64
name: 🐍 on ${{matrix.os}} with Python ${{matrix.python_version}}
runs-on: ${{matrix.os}}
steps:
- name: Clone Repository
uses: actions/checkout@v4
with:
submodules: recursive
- name: Setup ccache
uses: hendrikmuhs/[email protected]
with:
key: '${{matrix.os}}-pyfiction'
variant: ccache
save: true
max-size: 10G
- name: Setup Python
uses: actions/setup-python@v5
with:
python-version: ${{matrix.python_version}}
cache: 'pip'
- if: runner.os == 'Linux'
name: Setup mold
uses: rui314/setup-mold@v1
- name: Setup Z3 Solver
id: z3
uses: cda-tum/setup-z3@v1
with:
version: ${{env.Z3_VERSION}}
platform: ${{matrix.z3_platform}}
architecture: ${{matrix.architecture}}
env:
GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}}
- name: Build pyfiction
working-directory: ${{github.workspace}}
run: z3=${{env.ENABLE_Z3}} pip install '.[test]'
- name: Test
working-directory: ${{github.workspace}}
run: python -m unittest discover --verbose