File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ name : Build and Test
2+
3+ on :
4+ pull_request :
5+ types : [opened, reopened, synchronize, ready_for_review]
6+
7+ jobs :
8+ build-and-test :
9+ strategy :
10+ fail-fast : false
11+ matrix :
12+ include :
13+ - os : ubuntu-latest
14+ generator : Ninja
15+ - os : windows-latest
16+ generator : " Visual Studio 17 2022"
17+
18+ runs-on : ${{ matrix.os }}
19+
20+ steps :
21+ - name : Install additional dependencies
22+ if : matrix.os == 'ubuntu-latest'
23+ run : |
24+ sudo apt-get install -y --no-install-recommends mono-runtime libmono-system-json-microsoft4.0-cil libmono-system-data4.0-cil # TODO add mosquitto package
25+
26+ - name : Checkout project repo
27+ uses : actions/checkout@v4
28+ with :
29+ ref : ${{ github.event.inputs.branch || github.event.client_payload.branch || github.ref }}
30+
31+ - name : Configure project with CMake
32+ run : cmake -B build/output -S . -G "${{ matrix.generator }}" -DTODO_ENABLE_TESTS=ON -DCMAKE_BUILD_TYPE=Debug
33+
34+ - name : Build project with CMake
35+ run : cmake --build build/output --config Debug
36+
37+ - name : Install and run mosquitto Linux
38+ if : matrix.os == 'ubuntu-latest'
39+ run : |
40+ sudo apt-get install -y --no-install-recommends # TODO add mosquitto package name
41+ # TODO mosquitto run cmds
42+
43+ - name : Install and run mosquitto Windows
44+ if : matrix.os == 'windows-latest'
45+ run : # TODO install and run mosquitto
46+
47+ - name : Run project tests with CMake
48+ run : ctest --test-dir build/output --output-on-failure -C Debug
You can’t perform that action at this time.
0 commit comments