Skip to content

Commit

Permalink
improvement: added test pipeline
Browse files Browse the repository at this point in the history
  • Loading branch information
BartSte committed Dec 30, 2023
1 parent 3e2b24a commit 17159e6
Show file tree
Hide file tree
Showing 2 changed files with 38 additions and 0 deletions.
37 changes: 37 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
name: Tests

on:
push:
branches:
- main
- develop
pull_request:
branches:
- main
- develop

jobs:
run-tests:
runs-on: ubuntu-latest

steps:
- name: Checkout code
uses: actions/checkout@v2

- name: Install dependencies
run: |
sudo apt-get update
sudo apt-get install -y clang ninja-build git cmake qt6-base-dev qt6-multimedia-dev libboost-all-dev libspdlog-dev libcxxopts-dev libgl1-mesa-dev
- name: Build project
env:
CC: clang
CXX: clang++
CXXFLAGS: -std=c++17
run: |
cmake -S . -B build -G Ninja -DCMAKE_BUILD_TYPE=Release -DBUILD_TESTS=ON
cmake --build build
- name: Run tests
run: |
./build/bin/tests
1 change: 1 addition & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ message(STATUS "Build tests: ${BUILD_TESTS}")

set(CMAKE_CXX_STANDARD 20)
set(CMAKE_CXX_STANDARD_REQUIRED ON)
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -stdlib=libc++ -std=c++20")

set(CMAKE_AUTOMOC ON)
set(CMAKE_AUTORCC ON)
Expand Down

0 comments on commit 17159e6

Please sign in to comment.