mirror of
https://github.com/catchorg/Catch2.git
synced 2025-08-01 12:55:40 +02:00
Fix for #134
The INTERNAL_CATCH_MSG macro, which is used by INFO, WARN and FAIL places its lines in a do…while block so it can be used after an if statement with no block
This commit is contained in:
@@ -43,7 +43,8 @@ TEST_CASE( "./mixed/message/info/2", "INFO gets logged on failure" )
|
||||
|
||||
TEST_CASE( "./failing/message/fail", "FAIL aborts the test" )
|
||||
{
|
||||
FAIL( "This is a " << "failure" ); // This should output the message and abort
|
||||
if( true )
|
||||
FAIL( "This is a " << "failure" ); // This should output the message and abort
|
||||
}
|
||||
|
||||
TEST_CASE( "./failing/message/sections", "Output from all sections is reported" )
|
||||
|
Reference in New Issue
Block a user