Wire Sysio Wire Sysion 1.0.0
Loading...
Searching...
No Matches
sysio::testing::fc_exception_message_is Struct Reference

#include <tester.hpp>

Collaboration diagram for sysio::testing::fc_exception_message_is:

Public Member Functions

 fc_exception_message_is (const string &msg)
 
bool operator() (const fc::exception &ex)
 

Public Attributes

string expected
 

Detailed Description

Utility predicate to check whether an fc::exception message is equivalent to a given string

Definition at line 655 of file tester.hpp.

Constructor & Destructor Documentation

◆ fc_exception_message_is()

sysio::testing::fc_exception_message_is::fc_exception_message_is ( const string & msg)
inline

Definition at line 656 of file tester.hpp.

Member Function Documentation

◆ operator()()

bool sysio::testing::fc_exception_message_is::operator() ( const fc::exception & ex)

Definition at line 1200 of file tester.cpp.

1200 {
1201 auto message = ex.get_log().at( 0 ).get_message();
1202 bool match = (message == expected);
1203 if( !match ) {
1204 BOOST_TEST_MESSAGE( "LOG: expected: " << expected << ", actual: " << message );
1205 }
1206 return match;
1207 }
const log_messages & get_log() const
Here is the call graph for this function:

Member Data Documentation

◆ expected

string sysio::testing::fc_exception_message_is::expected

Definition at line 661 of file tester.hpp.


The documentation for this struct was generated from the following files: