A modern, C++-native, header-only, test framework for unit-tests, TDD and BDD - using C++11, C++14, C++17 and later (or C++03 on the Catch1.x branch)
C++ CMake Python Objective-C++ C Roff Other
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Failed to load latest commit information.
.github Added "How to test changes in PR" section to documentation Jun 26, 2017
CMake Add codecov.io coverage tracking Nov 27, 2017
artwork Tweaked logo Nov 7, 2017
contrib do not strip spaces from cmake discovered test names May 9, 2018
docs Make FALLBACK_STRINGIFIER documentation more explicit May 14, 2018
examples Namespace Catch CMake options Jan 18, 2018
include Move FALLBACK_STRINGIFIER to before the enum and range fallbacks May 14, 2018
misc Fixup various spelling errors (#1208) Mar 7, 2018
projects Ensure platform-independent output from SpecialException::what May 12, 2018
scripts Enable console colour in the approval tests on windows. May 14, 2018
single_include v2.2.2 Apr 6, 2018
test_package v2.2.2 Apr 6, 2018
third_party Bring in Clara v1.1.4 Mar 9, 2018
.gitattributes Keep .py files with LF endings so they can be executed from bash Feb 9, 2018
.gitignore Exclude benchmark dir Jan 5, 2018
.travis.yml Added GCC 8 to Travis. Updated test so that it warning isn't triggered. May 6, 2018
CMakeLists.txt Provide a polyfill over `std::to_string` May 9, 2018
CODE_OF_CONDUCT.md Create CODE_OF_CONDUCT.md Aug 17, 2017
LICENSE.txt Renamed licence file, license should now be detected by github Mar 20, 2017
README.md v2.2.2 Apr 6, 2018
appveyor.yml Disable PIP's version check on AppVeyor Mar 22, 2018
catch.pc.in Small fix to generate pc with include path Apr 2, 2018
codecov.yml Fix broken YAML in a way that codecov understands May 10, 2018
conanfile.py v2.2.2 Apr 6, 2018


catch logo

Github Releases Build Status Build status codecov Try online

The latest version of the single header can be downloaded directly using this link

Catch2 is released!

If you've been using an earlier version of Catch, please see the Breaking Changes section of the release notes before moving to Catch2. You might also like to read this blog post for more details.

What's the Catch?

Catch2 stands for C++ Automated Test Cases in a Header and is a multi-paradigm test framework for C++. which also supports Objective-C (and maybe C). It is primarily distributed as a single header file, although certain extensions may require additional headers.

How to use it

This documentation comprises these three parts: