BitShift Validate 0.1.0
BitShift Validate API Reference Documentation
Loading...
Searching...
No Matches
bitshift::validate::reporter Class Referenceabstract

#include <bitshift/validate/reporting.hxx>

Inheritance diagram for bitshift::validate::reporter:
bitshift::validate::ostream_reporter bitshift::validate::quiet_reporter

Public Member Functions

virtual ~reporter () noexcept
proxy log_setup (string const &file, int line)
proxy log_teardown (string const &file, int line)
proxy log_test_case (string const &name, string const &description, string const &file, int line)
proxy log_failure (string message, string file, int line)
void log_summary (uint16_t total, uint16_t ignored, uint16_t pass, uint16_t fail)

Protected Member Functions

 reporter ()
 reporter (reporter const &)=delete
 reporter (reporter &&)=delete
virtual void do_log_setup (string const &file, int line, string const &detail)=0
virtual void do_log_teardown (string const &file, int line, string const &detail)=0
virtual void do_log_test_case (string const &name, string const &description, string const &file, int line, string const &detail)=0
virtual void do_log_failure (string const &message, string const &file, int line, string const &detail)=0
virtual void do_log_summary (uint16_t total, uint16_t ignored, uint16_t pass, uint16_t fail)=0
reporteroperator= (reporter const &)=delete
reporteroperator= (reporter &&)=delete

Detailed Description

Abstract test suite reporter.

Constructor & Destructor Documentation

◆ ~reporter()

bitshift::validate::reporter::~reporter ( )
virtualnoexcept

Destructor.

◆ reporter() [1/3]

bitshift::validate::reporter::reporter ( )
protected

Constructor.

◆ reporter() [2/3]

bitshift::validate::reporter::reporter ( reporter const & )
protecteddelete

Copy-construction is disabled.

◆ reporter() [3/3]

bitshift::validate::reporter::reporter ( reporter && )
protecteddelete

Move-construction is disabled.

Member Function Documentation

◆ log_setup()

reporter::proxy bitshift::validate::reporter::log_setup ( string const & file,
int line )

Log test suite setup execution.

Parameters
fileThe file in which the setup is defined.
lineThe line on which the setup is defined.

◆ log_teardown()

reporter::proxy bitshift::validate::reporter::log_teardown ( string const & file,
int line )

Log test suite teardown execution.

Parameters
fileThe file in which the teardown is defined.
lineThe line on which the teardown is defined.

◆ log_test_case()

reporter::proxy bitshift::validate::reporter::log_test_case ( string const & name,
string const & description,
string const & file,
int line )

Log test case execution.

Parameters
nameThe name of the test case.
descriptionA description of the test case.
fileThe file in which the test case is defined.
lineThe line on which the test case is defined.

◆ log_failure()

reporter::proxy bitshift::validate::reporter::log_failure ( string message,
string file,
int line )

Log test case failure.

Parameters
messageA message describing the failure.
fileThe file in which the failure occurred.
lineThe line on which the error occurred.

◆ log_summary()

void bitshift::validate::reporter::log_summary ( uint16_t total,
uint16_t ignored,
uint16_t pass,
uint16_t fail )

Log test suite summary.

Parameters
totalThe total number of tests.
ignoredThe total number of ignored tests.
passThe total number of passed tests.
failThe total number of failed tests.

◆ do_log_setup()

virtual void bitshift::validate::reporter::do_log_setup ( string const & file,
int line,
string const & detail )
protectedpure virtual

Log test suite setup execution.

Parameters
fileThe file in which the setup is defined.
lineThe line on which the setup is defined.
detailExtra details.

Implemented in bitshift::validate::ostream_reporter, and bitshift::validate::quiet_reporter.

◆ do_log_teardown()

virtual void bitshift::validate::reporter::do_log_teardown ( string const & file,
int line,
string const & detail )
protectedpure virtual

Log test suite teardown execution.

Parameters
fileThe file in which the teardown is defined.
lineThe line on which the teardown is defined.
detailExtra details.

Implemented in bitshift::validate::ostream_reporter, and bitshift::validate::quiet_reporter.

◆ do_log_test_case()

virtual void bitshift::validate::reporter::do_log_test_case ( string const & name,
string const & description,
string const & file,
int line,
string const & detail )
protectedpure virtual

Log test case execution.

Parameters
nameThe name of the test case.
descriptionA description of the test case.
fileThe file in which the test case is defined.
lineThe line on which the test case is defined.
detailExtra details.

Implemented in bitshift::validate::ostream_reporter, and bitshift::validate::quiet_reporter.

◆ do_log_failure()

virtual void bitshift::validate::reporter::do_log_failure ( string const & message,
string const & file,
int line,
string const & detail )
protectedpure virtual

Log test case failure.

Parameters
messageA message describing the failure.
fileThe file in which the failure occurred.
lineThe line on which the error occurred.
detailExtra details.

Implemented in bitshift::validate::ostream_reporter, and bitshift::validate::quiet_reporter.

◆ do_log_summary()

virtual void bitshift::validate::reporter::do_log_summary ( uint16_t total,
uint16_t ignored,
uint16_t pass,
uint16_t fail )
protectedpure virtual

Log test suite summary.

Parameters
totalThe total number of tests.
ignoredThe total number of ignored tests.
passThe total number of passed tests.
failThe total number of failed tests.

Implemented in bitshift::validate::ostream_reporter, and bitshift::validate::quiet_reporter.

◆ operator=() [1/2]

reporter & bitshift::validate::reporter::operator= ( reporter const & )
protecteddelete

Copy-construction is disabled.

◆ operator=() [2/2]

reporter & bitshift::validate::reporter::operator= ( reporter && )
protecteddelete

Move-construction is disabled.