Browse Source

Throwing std::exception's instead of plain int's in the tests.

main
offa 6 years ago
parent
commit
14a838f9a2
2 changed files with 4 additions and 4 deletions
  1. +2
    -2
      test/ScopeFailTest.cpp
  2. +2
    -2
      test/ScopeSuccessTest.cpp

+ 2
- 2
test/ScopeFailTest.cpp View File

{ {
REQUIRE_CALL(m, deleter()); REQUIRE_CALL(m, deleter());
[[maybe_unused]] auto guard = sr::scope_fail{deleter}; [[maybe_unused]] auto guard = sr::scope_fail{deleter};
throw 3;
throw std::exception{};
} }
catch( ... ) catch( ... )
{ {
{ {
try try
{ {
throw 3;
throw std::exception{};
} }
catch( ... ) catch( ... )
{ {

+ 2
- 2
test/ScopeSuccessTest.cpp View File

try try
{ {
[[maybe_unused]] auto guard = sr::scope_success{deleter}; [[maybe_unused]] auto guard = sr::scope_success{deleter};
throw 3;
throw std::exception{};
} }
catch( ... ) catch( ... )
{ {
{ {
try try
{ {
throw 3;
throw std::exception{};
} }
catch( ... ) catch( ... )
{ {

Loading…
Cancel
Save