mirror of
https://github.com/catchorg/Catch2.git
synced 2025-08-01 12:55:40 +02:00
Addressed some warnings (mostly MSVC)
This commit is contained in:
@@ -210,6 +210,9 @@ TEST_CASE( "./succeeding/conditions/int literals",
|
||||
#pragma GCC diagnostic ignored "-Wsign-compare"
|
||||
#pragma GCC diagnostic ignored "-Wsign-conversion"
|
||||
#endif
|
||||
#ifdef _MSC_VER
|
||||
#pragma warning(disable:4389) // '==' : signed/unsigned mismatch
|
||||
#endif
|
||||
|
||||
TEST_CASE( "./succeeding/conditions//long_to_unsigned_x",
|
||||
"comparisons between int variables" )
|
||||
|
@@ -107,6 +107,9 @@ TEST_CASE_NORETURN( "./failing/exceptions/custom", "Unexpected custom exceptions
|
||||
{
|
||||
throw CustomException( "custom exception" );
|
||||
}
|
||||
#ifdef _MSC_VER
|
||||
#pragma warning(disable:4702) // unreachable code
|
||||
#endif
|
||||
|
||||
TEST_CASE( "./failing/exceptions/custom/nothrow", "Custom exceptions can be translated when testing for nothrow" )
|
||||
{
|
||||
|
@@ -47,7 +47,7 @@ TEST_CASE( "./mixed/message/info/2", "INFO gets logged on failure" )
|
||||
|
||||
TEST_CASE( "./failing/message/fail", "FAIL aborts the test" )
|
||||
{
|
||||
if( true )
|
||||
if( Catch::isTrue( true ) )
|
||||
FAIL( "This is a " << "failure" ); // This should output the message and abort
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user