Welcome to ApprovalTests.cpp.Nursery’s documentation!

Purpose

ApprovalTests.cpp.Nursery is a place to experiment with ideas for the ApprovalTests.cpp library.

Indices and tables

Docs

Note

All classes listed here are in the ApprovalTests namespace.

class ApprovalTests::FirstNFailuresReporter : public Reporter

Handle only up to a given number of failures. After that, just do nothing and return false.

Example use case: a GUI comparison tool creaks after being asked to show more than a certain number of image comparisons.

Public Functions

FirstNFailuresReporter(int maximum_failures, Reporter *reporter)
bool report(std::string received, std::string approved) const override
class ApprovalTests::CatchReporter : public Reporter

A reporter which uses Catch2 CHECK statement to check the output.

Note

This is only available if the Catch2 header was included before the header file declaring this class.

Public Functions

bool report(std::string received, std::string approved) const override