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)

Overview

Catch2 logo

Github Releases Build Status Build Status Code Coverage Try online Join the chat in Discord: https://discord.gg/4CWS9zD

Catch2 v3 is being developed!

You are on the devel branch, where the next major version, v3, of Catch2 is being developed. As it is a significant rework, you will find that parts of this documentation are likely still stuck on v2.

For stable (and documentation-matching) version of Catch2, go to the v2.x branch.

For migrating from the v2 releases to v3, you should look at our documentation. It provides a simple guidelines on getting started, and collects most common migration problems.

What's the Catch2?

Catch2 is mainly a unit testing framework for C++, but it also provides basic micro-benchmarking features, and simple BDD macros.

Catch2's main advantage is that using it is both simple and natural. Tests autoregister themselves and do not have to be named with valid identifiers, assertions look like normal C++ code, and sections provide a nice way to share set-up and tear-down code in tests.

How to use it

This documentation comprises these three parts:

More

Issues
  • CATCH needs a more searchable name

    CATCH needs a more searchable name

    This is not the first time I run into this and I always just shrugged it off before, but after completely failing to find anything about the issue I was interested in (whether anybody has already done something to help with migrating the existing tests using CppUnit to CATCH) I have to say that this is a real problem: it's just impossible to find anything about CATCH using web search.

    It needs to use some unique name or at least not a word so prevalent when speaking about unit testing in C++ (because I'm not interested in finding about how to catch exceptions in CppUnit, damn it).

    It can be anything you like, I don't know if you prefer obvious but dull names (CppCatch, CatchUTF, ...), some other abbreviation (C++ Automated Tests Now Are Possible) or stupid puns (Notry, Dogch, ...) or hopefully something better I can't find, but it needs to be something you could enter into your search engine and actually find something related to CATCH.

    Discussion 
    opened by vadz 87
  • Junit XML reporter

    Junit XML reporter

    It should be possible to obtain xml reports that follow the schema for JUnit - for consumption by third party tools

    opened by philsquared 76
  • Never-ending loop wjhen the test case Failed

    Never-ending loop wjhen the test case Failed

    If I use this piece of code:

    #define CATCH_CONFIG_MAIN
    #include "catch.hpp"
    
    #include "TCACAVAUtilities.h"
    
    TEST_CASE( "TCACAVAUtilities::CreateColorFromRGB", "[CreateColorFromRGB]" ) {
        REQUIRE( TCACAVAUtilities::CreateColorFromRGB(0, 0, 0) == 255 );
    }
    

    The result is:

    C:\SourceCode\CVS_ROOT\CAVA\develop_clean\win_b64\code\bin>TCACAVACreateBaseCatalog.exe
    All tests passed (1 assertion in 1 test case)
    

    But If I use this code:

    #define CATCH_CONFIG_MAIN
    #include "catch.hpp"
    
    #include "TCACAVAUtilities.h"
    
    TEST_CASE( "TCACAVAUtilities::CreateColorFromRGB", "[CreateColorFromRGB]" ) {
        REQUIRE( TCACAVAUtilities::CreateColorFromRGB(1, 0, 0) == 255 );
        REQUIRE( TCACAVAUtilities::CreateColorFromRGB(0, 0, 0) == 255 );
    }
    

    The result is:

    -------------------------------------------------------------------------------
    TCACAVAUtilities::CreateColorFromRGB
    -------------------------------------------------------------------------------
    C:\SourceCode\CVS_ROOT\CAVA\develop_clean\TCACAVACatalog\TCACAVACreateBaseCatalo
    g.m\src\TCACAVACreateBaseCatalog.cpp(6)
    ...............................................................................
    
    C:\SourceCode\CVS_ROOT\CAVA\develop_clean\TCACAVACatalog\TCACAVACreateBaseCatalo
    g.m\src\TCACAVACreateBaseCatalog.cpp(7): FAILED:
      REQUIRE( TCACAVAUtilities::CreateColorFromRGB(1, 0, 0) == 255 )
    with expansion:
      0x10000ff == 255
    
    -------------------------------------------------------------------------------
    TCACAVAUtilities::CreateColorFromRGB
    -------------------------------------------------------------------------------
    C:\SourceCode\CVS_ROOT\CAVA\develop_clean\TCACAVACatalog\TCACAVACreateBaseCatalo
    g.m\src\TCACAVACreateBaseCatalog.cpp(6)
    ...............................................................................
    
    C:\SourceCode\CVS_ROOT\CAVA\develop_clean\TCACAVACatalog\TCACAVACreateBaseCatalo
    g.m\src\TCACAVACreateBaseCatalog.cpp(7): FAILED:
      REQUIRE( TCACAVAUtilities::CreateColorFromRGB(1, 0, 0) == 255 )
    with expansion:
      0x10000ff == 255
    
    -------------------------------------------------------------------------------
    TCACAVAUtilities::CreateColorFromRGB
    -------------------------------------------------------------------------------
    C:\SourceCode\CVS_ROOT\CAVA\develop_clean\TCACAVACatalog\TCACAVACreateBaseCatalo
    g.m\src\TCACAVACreateBaseCatalog.cpp(6)
    ...............................................................................
    
    C:\SourceCode\CVS_ROOT\CAVA\develop_clean\TCACAVACatalog\TCACAVACreateBaseCatalo
    g.m\src\TCACAVACreateBaseCatalog.cpp(7): FAILED:
      REQUIRE( TCACAVAUtilities::CreateColorFromRGB(1, 0, 0) == 255 )
    with expansion:
      0x10000ff == 255
    
    -------------------------------------------------------------------------------
    TCACAVAUtilities::CreateColorFromRGB
    -------------------------------------------------------------------------------
    C:\SourceCode\CVS_ROOT\CAVA\develop_clean\TCACAVACatalog\TCACAVACreateBaseCatalo
    g.m\src\TCACAVACreateBaseCatalog.cpp(6)
    ...............................................................................
    
    C:\SourceCode\CVS_ROOT\CAVA\develop_clean\TCACAVACatalog\TCACAVACreateBaseCatalo
    g.m\src\TCACAVACreateBaseCatalog.cpp(7): FAILED:
      REQUIRE( TCACAVAUtilities::CreateColorFromRGB(1, 0, 0) == 255 )
    with expansion:
      0x10000ff == 255
    
    -------------------------------------------------------------------------------
    TCACAVAUtilities::CreateColorFromRGB
    -------------------------------------------------------------------------------
    C:\SourceCode\CVS_ROOT\CAVA\develop_clean\TCACAVACatalog\TCACAVACreateBaseCatalo
    g.m\src\TCACforrtl: error (200): program aborting due to control-C event
    Image              PC                Routine            Line        Source
    
    libifcoremd.dll    00000000100BAB14  Unknown               Unknown  Unknown
    libifcoremd.dll    00000000100B46B9  Unknown               Unknown  Unknown
    libifcoremd.dll    00000000100A1017  Unknown               Unknown  Unknown
    libifcoremd.dll    0000000010021BF8  Unknown               Unknown  Unknown
    libifcoremd.dll    000000001002DDC8  Unknown               Unknown  Unknown
    kernel32.dll       00000000774F4803  Unknown               Unknown  Unknown
    kernel32.dll       00000000774B652D  Unknown               Unknown  Unknown
    ntdll.dll          00000000776EC541  Unknown               Unknown  Unknown
    

    The never-ending loop which should I stop with CTRL+C.

    Where is the problem ? Do I something wrong ?

    opened by dsamek 44
  • Xcode/XCTest Runner Integration

    Xcode/XCTest Runner Integration

    This patch adds support for XCTest integration by inverting the usual Catch behavior; rather than using Catch as the test runner, we dynamically register XCTestCase classes with the Objective-C runtime to allow Xcode's test runner to execute (and report on) Catch-defined test cases.

    To use this implementation, a project need only include "XCTestRunner.mm" in their unit test build -- the +[XCTestCaseCatchRegistry load] method will insert an XCTestRegistryHub instance that automatically registers XCTestCase classes for any Catch test cases defined within the image.

    +load methods by definition will run prior to C++ static initializers in the same image, ensuring that we insert our registry prior to any TestCase instances registering themselves.

    Currently, our granularity is limited to test cases -- we can't report on section execution without first registering the section as a test instance in the XCTestCase, and this would require static access to the list of sections/subsections defined within a TestCase or Section.

    This approach is based on the XCTest registration code I wrote for XSmallTest: https://github.com/landonf/XSmallTest

    opened by landonf 43
  • Add Catch::toString support for containers

    Add Catch::toString support for containers

    In order to enhance REQUIRE and CHECK error message when testing standard containers, add overloads of Catch::toString for:

    • std::pair
    • ~~std::deque~~
    • ~~std::list~~
    • ~~std::array (c++11)~~
    • ~~std::forward_list (c++11)~~
    • ~~(more types upcoming)~~
    • any type that has a container api (no need to add support for each container individually)

    Those types were printed as "{?}" (default toString implementation for unsupported class). This was contradictory with the documentation:

    "Most [...] std types are supported out of the box"

    when in fact only string, vector and tupple were supported.

    Detail:

    • Renamed the toStringVector.cpp test file to toStringContainers.cpp and type parametrized the vector tests to run them also for deque and list.
    • ~~The overhead of including all the standard container headers is negligable.~~ => No longer needed, types are treated as containers if they fulfill (some) of the container concept constraints.
    • Types are consider containers if they contain value_type and const_iterator members and have begin and end support (members or ADL findable) returning a const_iterator. const_iterator::operator* must also return a const value_type &
    • Beware that a trying to printing a type fulfilling those requirements but returning invalid iterators will results in undefined behaviour. In such case specialize the Catch::IsContainer trait to contain static const bool value = false in order revert to the default behaviour (printing "{?}").
    opened by mat-tso 36
  • #include <catch2/catch.hpp> vs #include

    #include vs #include "catch.hpp"

    Just wondering: It seems more ideomatic to me to include the library name as part of the include name instead of just using the header file name alone. On the other hand, for a single header library there is of course not a big need/difference for it unless the header name is likely to clash with a different file name.

    So I was wondering whether your preference of

    #include "catch.hpp"
    

    over

    #include <catch2/catch.hpp>
    

    was deliberate or more like "for historic reasons" / "didn't care".

    Discussion 
    opened by MikeGitb 32
  • Tests sorted according to random index instead of random hash

    Tests sorted according to random index instead of random hash

    Description

    Use a random number instead of a hash to sort the tests.

    Motivation

    In v2.x, test cases with names differing only in the last character are almost always run one after the other. For example, for 4 tests called "a1", "a2", "b1" and "b2", only 8 combinations out of the possible 24 were observed in 1000 runs with different seeds.

    Tweak request 
    opened by loximann 27
  • Build error in Visual Studio 2013

    Build error in Visual Studio 2013

    I tried to compile the following program using the single-header of the master branch.

    #define CATCH_CONFIG_MAIN
    #include "catch.hpp"
    

    In Visual Studio 2013 Preview, the first error is:

    catch.hpp(1980): error C2694: 'Catch::StreamBufBase::~StreamBufBase(void)': overriding virtual function has less restrictive exception specification than base class virtual member function 'std::basic_streambuf<char,std::char_traits<char>>::~basic_streambuf(void) throw()'
    1>          H:\petter\catch\single_include\catch.hpp(1980) : see declaration of 'Catch::StreamBufBase::~StreamBufBase'
    1>          C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\include\streambuf(78) : see declaration of 'std::basic_streambuf<char,std::char_traits<char>>::~basic_streambuf'
    
    opened by PetterS 27
  • memory leaks detected by MSVCRT debugging facilities

    memory leaks detected by MSVCRT debugging facilities

    Extra information

    Environment: Windows 10 Compiler: Microsoft (R) Compiler Version 19.11.25547 for x64 (VS2017 15.4.4) Compiler options: -sdl -guard:cf -Zc:inline -Zc:rvalueCast -Zc:referenceBinding -Zc:strictStrings -std:c++latest Version of Catch: Current master git source

    Description

    I've just started with Catch and I created a test project following code as described in the Catch2/docs/tutorial.md. I added the #define CATCH_CONFIG_RUNNER and implemented my own wmain, basically a copy of the default. I also added the _CrtDumpMemoryLeaks() diagnostics in the end of wmain. I get the following output:

    Detected memory leaks!
    Dumping objects ->
    {223} normal block at 0x0000013DA7B8EC30, 16 bytes long.
     Data: < ZQ             > B8 5A 51 F6 F7 7F 00 00 00 00 00 00 00 00 00 00 
    Object dump complete.
    

    Is it possible this could be a false indication of memory allocated by Catch waiting to be released at program exit? If so, is it by design?

    Steps to reproduce

    Compile the source file catch_tutorial.cpp.txt

    Possible bug 
    opened by BeErikk 27
  • testing getting skipped

    testing getting skipped

    It seems when sections are nested within an iteration, only the first iteration gets run. I do this kind of testing a lot and it would be nice if you could have sections within iterations.

    Ideally I would like to be able to do all the permutations of three or four variables, which is currently not possible. At the moment I find myself repeating code quite a lot with testing, and I'd like to have some more functional tests.

    TEST_CASE( (char*)"Cyclohexane", (char*)"[cyclohexane],[validation]" ) 
        {
            Fluid *CHEX = get_fluid(get_Fluid_index("Cyclohexane"));
            double mm = CHEX->params.molemass;
            validator_element data[] = {
                validator_element("T",300.0,"D",9.4*mm,"P",24.173705*1e6),
                validator_element("T",300.0,"D",9.4*mm,"O",115.28612/mm),
                validator_element("T",300.0,"D",9.4*mm,"C",154.76968/mm),
                validator_element("T",300.0,"D",9.4*mm,"A",1383.3876),
                validator_element("T",500.0,"D",6.5*mm,"P",3.9246630*1e6),
                validator_element("T",500.0,"D",6.5*mm,"O",192.52079/mm),
                validator_element("T",500.0,"D",6.5*mm,"C",255.57110/mm),
                validator_element("T",500.0,"D",6.5*mm,"A",434.13058),
                validator_element("T",500.0,"D",0.7*mm,"P",1.9981172*1e6),
                validator_element("T",500.0,"D",0.7*mm,"O",191.96468/mm),
                validator_element("T",500.0,"D",0.7*mm,"C",235.52304/mm),
                validator_element("T",500.0,"D",0.7*mm,"A",155.34798),
                validator_element("T",600.0,"D",3.5*mm,"P",6.8225506*1e6),  
                validator_element("T",600.0,"D",3.5*mm,"O",232.79249/mm),
                validator_element("T",600.0,"D",3.5*mm,"C",388.55212/mm),
                validator_element("T",600.0,"D",3.5*mm,"A",150.53314),
                validator_element("T",553.6,"D",3.3*mm,"P",4.0805433*1e6),
                validator_element("T",553.6,"D",3.3*mm,"O",224.19580/mm), 
                validator_element("T",553.6,"D",3.3*mm,"C",199224.62/mm), 
                validator_element("T",553.6,"D",3.3*mm,"A",87.913862)
            };
    
            //Now actually construct the vector
            std::vector<validator_element> elements(data, data + sizeof(data) / sizeof(validator_element));     
    
            for (std::vector<validator_element>::iterator it = elements.begin(); it != elements.end(); it++)
            {
                validator_element &el = *it;
                SECTION((char*)"validate")
                {
                    double eos = PropsSI((char*)el.in5.c_str(), (char*)el.in1.c_str(), el.in2, (char*)el.in3.c_str(), el.in4, "Cyclohexane")+1000;
                    double valid = el.in6;
                    CHECK(valid == eos);
                }
            }
        }
    
    opened by ibell 26
  • Custom main when using amalgamated header/cpp

    Custom main when using amalgamated header/cpp

    I want to provide my own main function, and I use amalgamated version of library which has "main" hard-coded. What can I do except patching my version of Catch locally? I would make a PR, but I don't know what's the expected solution.

    Thanks, Eugene.

    opened by eugeneko 0
  • CMake: does not include cpp files in tests build

    CMake: does not include cpp files in tests build

    According to the guide of integrating catch2 into cmake, I added the following to my CMakeLists.txt:

    Include(FetchContent)
    
    FetchContent_Declare(
        Catch2
        GIT_REPOSITORY https://github.com/catchorg/Catch2.git
        GIT_TAG        v3.0.0-preview3
    )
    
    FetchContent_MakeAvailable(Catch2)
        
    add_executable(tests tests/test.cpp)
    target_link_libraries(tests PRIVATE Catch2::Catch2WithMain)
    

    which worked perfectly. However, when I am trying to write tests for my own files, I get a bunch of error LNK2019: unresolved external symbol error, such as:

    [build] test.obj : error LNK2019: unresolved external symbol "public: __cdecl EventListener::EventListener(void)" ([email protected]@[email protected]) referenced in function "public: static class EventListener & __cdecl EventListener::Instance(void)" ([email protected]@@[email protected]) [D:\projects\final-project-cyborgwizards\build\tests.vcxproj]
    [build] test.obj : error LNK2019: unresolved external symbol "public: void __cdecl EventListener::BroadcastEvent(class Event)" ([email protected]@@[email protected]@@Z) referenced in function "void __cdecl ____C_A_T_C_H____T_E_S_T____0(void)" ([email protected]@YAXXZ) [D:\projects\final-project-cyborgwizards\build\tests.vcxproj]
    

    According to the Microsoft guide, the problem might be that my own cpp files are not compiled. In /build/my-project-name.dir/Debug, all of my cpp files have a corresponding .obj file inside. However in /build/test.dir/Debug, there is only a .obj file test.obj. I know that I should write the files needed for compiling & linking in add_executable(), but writing something like add_executable(tests tests/test.cpp src/*.cpp) doesn't work. How can I add all cpp files?

    opened by Power-tile 0
  • Add AllTrue, AnyTrue, NoneTrue generic range matchers

    Add AllTrue, AnyTrue, NoneTrue generic range matchers

    Description

    This PR adds AllTrue, AnyTrue, NoneTrue generic range matchers, which match a range if all, any, or none of the elements in a range are true, respectively.

    GitHub Issues

    Addresses issue #2109.

    opened by schallerr 1
  • CATCH_CONFIG_DISABLE fails CAPTURE(i,j)

    CATCH_CONFIG_DISABLE fails CAPTURE(i,j)

    Describe the bug when I turn on CATCH_CONFIG_DISABLE, all CAPTURE(i,j) , i.e. more than one arg will err.

    Expected behavior No such error

    Reproduction steps Build below code with -DCATCH_CONFIG_DISABLE

    #include "catch.hpp"
    
    TEST_CASE("generators") {
        auto i = GENERATE(as<std::string>(), "a", "b", "c");
        SECTION("one") {
            auto j = GENERATE(range(8, 11), 2);
            CAPTURE(i, j);
            SUCCEED();
        }
        SECTION("two") {
            auto j = GENERATE(3, 141, 1.379);
            CAPTURE(i, j);
            SUCCEED();
        }
    }
    
    // cross-product of two ranges.
    TEST_CASE("100x100 ints", "[.][approvals]") {
        auto x = GENERATE(range(0, 100));
        auto y = GENERATE(range(200, 300));
        CHECK(x < y);
    }
    

    will lead to below errs:

    generate.cpp:7:21: error: macro "CAPTURE" passed 2 arguments, but takes just 1
        7 |         CAPTURE(i, j);
          |                     ^
    In file included from generate.cpp:1:
    catch.hpp:17887: note: macro "CAPTURE" defined here
    17887 | #define CAPTURE( msg ) (void)(0)
          | 
    generate.cpp:12:21: error: macro "CAPTURE" passed 2 arguments, but takes just 1
       12 |         CAPTURE(i, j);
          |                     ^
    In file included from generate.cpp:1:
    catch.hpp:17887: note: macro "CAPTURE" defined here
    17887 | #define CAPTURE( msg ) (void)(0)
          | 
    generate.cpp: In function ‘void ____C_A_T_C_H____T_E_S_T____0()’:
    generate.cpp:7:9: error: ‘CAPTURE’ was not declared in this scope
        7 |         CAPTURE(i, j);
          |         ^~~~~~~
    generate.cpp:12:9: error: ‘CAPTURE’ was not declared in this scope
       12 |         CAPTURE(i, j);
    

    Platform information:

    • OS: Linux
    • Compiler+version: G++ v9.3
    • Catch version: v2.13.7, the newest

    Additional context

    My fix is below to get it working:

    17886c17886,17887
    < #define CAPTURE( msg ) (void)(0)
    ---
    > #define CAPTURE( ... ) (void)(0)
    
    Bug Good First Issue 
    opened by laoshaw 0
  • Replace link to Clara's repository for doc with our own documentation page

    Replace link to Clara's repository for doc with our own documentation page

    Clara, the command line parser library in Catch2, stopped being a separate project from Catch2 about 3 years ago. Since then it was only developed inside Catch2, while the original upstream repository was made inactive and archived.

    Given that Clara-inside-Catch2 has also slowly diverged from the separate version, we should provide its documentation inside the Catch2 repo, and replace the link to upstream docs in the own-main docs with link to our own documentation page for Clara.

    Documentation Good First Issue 
    opened by horenmar 0
  • Add a command-line flag to print status updates while tests are running.

    Add a command-line flag to print status updates while tests are running.

    Description Right now Catch2 prints nothing until all tests have completed. It would be helpful if there was some easy way to have it print a line each time it is starting a new test case so that I can see whether the tests are making progress. (Also to keep me entertained enough to avoid alt-tabbing to a browser and losing 15 minutes. 🙄) I'm thinking something nice and simple like:

    Starting test (7/135): NAME_OF_TEST

    You could even have it start with \r and not end with \n so that it only takes up a single terminal line, like ninja does when the output isatty

    opened by RedBeard0531 1
  • Unused variable warnings when compiling with nvcc + gcc

    Unused variable warnings when compiling with nvcc + gcc

    When compiling CUDA files with nvcc (CUDA 11.3 and GCC 9.4), when including catch2 and declaring a simple test case, I'm getting warnings such as variable "[...]autoRegistrar1" was declared but never referenced. Is there a way to get rid of these warnings?

    Platform information:

    • OS: Linux x86_64
    • Compiler+version: NVCC 11.3 / GCC 9.4.0
    • Catch version: v2.13.0 [included as part of CMake build, with cmake 3.17.0]
    opened by MatthiasKohl 1
  • Test case name hashing should consider tags and class name too

    Test case name hashing should consider tags and class name too

    Describe the bug Recently I changed the "unique test case" criteria to allow test cases with same name, but different tags, or same names and tags but different class name (when a test case hangs off a type).

    However, we also hash test cases when ordering them randomly (to get subset-stable ordering), and the hashing currently only considers test case name, which means that hash collisions are now much more realistic (in fact the collision is guaranteed if two test cases have same name, which is a desired property by some users).

    Note that this doesn't break the subset invariant, because we use the ordering of test case infos to break ties, which handles tags and class name properly

    Expected behavior To fix this, the hasher should also consider tags and class name.

    Additional context This change also makes the hasher complex enough that it should be promoted to a header and receive direct unit tests.

    Bug Good First Issue 
    opened by horenmar 0
  • Log the values returned by GENERATE

    Log the values returned by GENERATE

    Whenever I use GENERATE, I find myself using CAPTURE to log the generated value(s) to be able to pinpoint for which value a test case failed. It would be nice if GENERATE would automatically log the returned values (or create a SECTION for them) to make this clear in the default output.

    opened by mtvec 0
  • Capture and suppress stdout and stderr if there is no error

    Capture and suppress stdout and stderr if there is no error

    Description The python pytest framework only displays stdout and stderr if there is an error in the unit test. And then it displays each separately, not interleaved.

    Additional context It would be great if catch2 did this. #49 implies that it does, but it doesn't seem to.

    opened by simsong 0
Releases(v2.13.7)
Owner
Catch Org
Organisation account for Catch repositories
Catch Org
C++ Unit Testing Easier: A Header-only C++ unit testing framework

CUTE C++ Unit Testing Easier: A Header-only C++ unit testing framework usually available as part of the Cevelop C++ IDE (http://cevelop.com) Dependenc

Peter Sommerlad 32 Nov 9, 2021
Various Framework to do Unit Test in C++

Unit Test in C++ There are many frameworks to performs unit test in C++, we will present the most popular ones and show how to use them. The testing f

Yassine 2 Nov 18, 2021
TestFrame - This is a test framework that uses Raylib and ImGui together to help test and develop concepts

This is a test framework that uses Raylib and ImGui together to help test and develop concepts. It is made using C++ because it uses classes for windows and views.

Jeffery Myers 18 Nov 7, 2021
The C Unit Testing Library on GitHub is a library designed for easy unit testing in C

The C Unit Testing Library on GitHub is a library designed for easy unit testing in C. It was written by Brennan Hurst for the purpose of providing a J-Unit-like testing framework within C for personal projects.

null 1 Oct 11, 2021
Modern c++17 unit testing framework on Microsoft Windows, Apple macOS, Linux, iOS and android.

tunit Modern c++17 unit testing framework on Windows, macOS, Linux, iOS and android. Continuous Integration build status Operating system Status Windo

Gammasoft 6 Oct 1, 2021
A dynamic mock tool for C/C++ unit test on Linux&MacOS X86_64

lmock 接口 替换一个函数,修改机器指令,用新函数替换旧函数,支持全局函数(包括第三方和系统函数)、成员函数(包括静态和虚函数)

null 34 Nov 26, 2021
A complete unit testing framework in a header

liblittletest A complete unit testing framework in a header liblittletest is an easy to use all-in-an-header testing framework; all you have to do in

Sebastiano Merlino 13 Nov 11, 2021
UT: C++20 μ(micro)/Unit Testing Framework

"If you liked it then you "should have put a"_test on it", Beyonce rule UT / μt | Motivation | Quick Start | Overview | Tutorial | Examples | User Gui

boost::ext 706 Dec 2, 2021
Harbour DB speed tests comparison

hbDBSpeedTests Harbour DB speed tests comparison - Registers Count: 821051 MySql configuration( 1 or 2 ) /data/mysql/dbstru.zip - Import structure of

DIEGO H FAZIO 3 Nov 18, 2021
End to end test framework designed for Juce applications

JUCE End to End test framework What is it? This package provides a mechanism to end-to-end test a JUCE application Prerequisites CMake. Must be 3.18 o

Focusrite Audio Engineering Ltd. 21 Dec 7, 2021
Handy C++ test framework

C++ Voyager Test Framework Voyager is a simple and handy C++ Unit Test framework. It is designed to be beautiful and expressive both. Try it to feel i

Anatoly Frolov 3 Nov 29, 2021
Header only C++14 mocking framework

Trompeloeil Get: trompe l'oeil noun (Concise Encyclopedia) Style of representation in which a painted object is intended to deceive the viewer into be

Björn Fahller 588 Nov 27, 2021
A micro unit-testing library for C/C++

µ-test A micro unit testing framework for C/C++ to get you up and running with unit-testing ASAP (even without libc). Usage Simply include the C and h

Trevor McKay 1 Nov 30, 2021
📝 One of the difficult unit tester for ft_containers project

ft_containers-unit-test About ft containers unit test is a complete testing for project of school 21/ecole 42 and allowing you test your containers: V

Erik 12 Nov 26, 2021
An area to test reading in ATLAS xAOD format and writing out to Parquet

xaod_to_parquet An area to test reading in ATLAS xAOD format and writing out to Parquet Getting the Code Clone the repository with the --recursive fla

Daniel Antrim 2 Nov 19, 2021
PlatformIO + BL602 Bouffalo Arduino Core Test

PlatformIO + BL602 Bouffalo Arduino Core Test Description Uses A custom extension of the PlatformIO SiFive Platform (https://github.com/maxgerhardt/pl

Maximilian Gerhardt 2 Sep 29, 2021
A test showing a flipped bit in a file encrypted on two different machines

ChaCha ASM Test I have observed that the ChaCha cipher may have very rarely divergent code paths for AVX vs. SSE. I have seen this in earlier CryptoPP

Austin Clifton 2 Nov 20, 2021
A tool to test if a shared library is dlopen'ble

A tool to test if a shared library is dlopen'ble

Mahin Ahmed 1 Oct 17, 2021
Header-only C++11 library for property-based testing.

autocheck Header-only C++11 library for QuickCheck (and later, SmallCheck) testing. Please consult the wiki for documentation. Install conan remote ad

John Freeman 115 Oct 18, 2021