diff --git a/.gitea/workflows/cpp-tests.yml b/.gitea/workflows/cpp-tests.yml new file mode 100644 index 0000000..fd8c038 --- /dev/null +++ b/.gitea/workflows/cpp-tests.yml @@ -0,0 +1,37 @@ +name: C++ Tests + +on: + push: + branches: + - main + - dev + - "claude/**" + pull_request: + +jobs: + test: + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v4 + + - name: Install build tools + run: | + sudo apt-get update -qq + sudo apt-get install -y --no-install-recommends \ + cmake \ + g++ \ + git \ + ca-certificates + + - name: Configure (Release, tests enabled) + run: | + cmake -S code -B build \ + -DCMAKE_BUILD_TYPE=Release \ + -DBUILD_TESTING=ON + + - name: Build test binary + run: cmake --build build --target conformallab_tests -j$(nproc) + + - name: Run tests + run: ctest --test-dir build -R conformallab_tests --output-on-failure