-
Notifications
You must be signed in to change notification settings - Fork 11
119 lines (99 loc) · 3.4 KB
/
ci.yml
File metadata and controls
119 lines (99 loc) · 3.4 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
110
111
112
113
114
115
116
117
118
119
name: CI
on:
push:
branches: [main]
pull_request:
branches: [main]
env:
CARGO_TERM_COLOR: always
LIBCLANG_PATH: /usr/lib/llvm-18/lib
Z3_SYS_Z3_HEADER: /usr/include/z3.h
jobs:
build-and-test:
runs-on: self-hosted
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Show CPU count
run: nproc
- name: Build
run: cargo build --release -j $(nproc)
- name: Run tests
run: cargo test --release -j $(nproc) -- --test-threads=$(nproc)
- name: Test CMake example project
run: |
export PATH="$HOME/.cargo/bin:$PATH"
cd cmake-example-project
rm -rf build
mkdir build && cd build
cmake ..
make -j $(nproc)
parity-matrix:
runs-on: self-hosted
needs: build-and-test
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Run parity matrix
run: |
export PATH="$HOME/.cargo/bin:$PATH"
./tests/transpile_tests/run_parity_matrix.sh \
--work-root "${RUNNER_TEMP}/rusty-parity-matrix"
- name: Upload parity matrix artifacts on failure
if: failure()
uses: actions/upload-artifact@v4
with:
name: parity-matrix-artifacts-${{ github.run_id }}
path: |
${{ runner.temp }}/rusty-parity-matrix/either/**
${{ runner.temp }}/rusty-parity-matrix/tap/**
${{ runner.temp }}/rusty-parity-matrix/cfg-if/**
${{ runner.temp }}/rusty-parity-matrix/take_mut/**
${{ runner.temp }}/rusty-parity-matrix/arrayvec/**
${{ runner.temp }}/rusty-parity-matrix/semver/**
${{ runner.temp }}/rusty-parity-matrix/bitflags/**
${{ runner.temp }}/rusty-parity-matrix/smallvec/**
${{ runner.temp }}/rusty-parity-matrix/itertools/**
${{ runner.temp }}/rusty-parity-matrix/once_cell/**
if-no-files-found: warn
retention-days: 14
cpp-module-interop-compile:
runs-on: self-hosted
needs: build-and-test
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Run cpp module interop compile check
run: |
export PATH="$HOME/.cargo/bin:$PATH"
./tests/transpile_tests/run_cpp_module_interop_compile.sh \
--work-dir "${RUNNER_TEMP}/rusty-cpp-module-interop"
- name: Upload cpp module interop artifacts on failure
if: failure()
uses: actions/upload-artifact@v4
with:
name: cpp-module-interop-artifacts-${{ github.run_id }}
path: |
${{ runner.temp }}/rusty-cpp-module-interop/**
if-no-files-found: warn
retention-days: 14
cpp-std-complex-compile:
runs-on: self-hosted
needs: build-and-test
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Run cpp std complex compile check
run: |
export PATH="$HOME/.cargo/bin:$PATH"
./tests/transpile_tests/run_cpp_std_complex_compile.sh \
--work-dir "${RUNNER_TEMP}/rusty-cpp-std-complex"
- name: Upload cpp std complex artifacts on failure
if: failure()
uses: actions/upload-artifact@v4
with:
name: cpp-std-complex-artifacts-${{ github.run_id }}
path: |
${{ runner.temp }}/rusty-cpp-std-complex/**
if-no-files-found: warn
retention-days: 14