GitLab CI and Distributed Builds
Develop C++ unit testing with Catch2, JUnit, and GitLab CI

Develop C++ unit testing with Catch2, JUnit, and GitLab CI

7/2/2024 · Fatima Sarah Khalid

What this post added

This post introduces the integration of Catch2 for C++ unit testing within GitLab CI. It provides a detailed walkthrough of setting up Catch2 as a Git submodule, structuring the C++ project into separate header and source files for better testability, and configuring CMakeLists.txt to build both the application and its tests. It also demonstrates how to write basic tests using Catch2 macros and assertions, and outlines the steps for creating a `.gitlab-ci.yml` file to automate the build and test process.

Read the original post ↗