REQUIRE_THROWS_AS is now reported with expected type as well

Also updated tests to reflect this change.
This commit is contained in:
Martin Hořeňovský
2017-02-09 12:41:16 +01:00
parent e543cc0646
commit 9952dda524
5 changed files with 19 additions and 19 deletions

View File

@@ -131,7 +131,7 @@ ExceptionTests.cpp:<line number>
...............................................................................
ExceptionTests.cpp:<line number>: FAILED:
REQUIRE_THROWS_AS( throwCustom() )
REQUIRE_THROWS_AS( throwCustom(), std::exception )
due to unexpected exception with message:
custom exception - not std
@@ -245,12 +245,12 @@ ExceptionTests.cpp:<line number>
...............................................................................
ExceptionTests.cpp:<line number>: FAILED:
CHECK_THROWS_AS( thisThrows() )
CHECK_THROWS_AS( thisThrows(), std::string )
due to unexpected exception with message:
expected exception
ExceptionTests.cpp:<line number>: FAILED:
CHECK_THROWS_AS( thisDoesntThrow() )
CHECK_THROWS_AS( thisDoesntThrow(), std::domain_error )
because no exception was thrown where one was expected:
ExceptionTests.cpp:<line number>: FAILED: