mirror of
https://github.com/catchorg/Catch2.git
synced 2025-05-25 22:19:25 +00:00
Refactored assertion builder stuff out of expression builder
This commit is contained in:
parent
c96f9330a0
commit
3ad13256e1
6 changed files with 102 additions and 111 deletions
|
@ -148,10 +148,6 @@ namespace Catch {
|
|||
return actOnCurrentResult();
|
||||
}
|
||||
|
||||
virtual void acceptMessage( const std::string& msg ) {
|
||||
m_currentResult.setMessage( msg );
|
||||
}
|
||||
|
||||
virtual void testEnded( const AssertionResult& result ) {
|
||||
if( result.getResultType() == ResultWas::Ok ) {
|
||||
m_totals.assertions.passed++;
|
||||
|
@ -293,8 +289,10 @@ namespace Catch {
|
|||
// This just means the test was aborted due to failure
|
||||
}
|
||||
catch(...) {
|
||||
acceptMessage( getRegistryHub().getExceptionTranslatorRegistry().translateActiveException() );
|
||||
acceptResult( ResultWas::ThrewException );
|
||||
m_currentResult
|
||||
.setResultType( ResultWas::ThrewException )
|
||||
<< translateActiveException();
|
||||
actOnCurrentResult();
|
||||
}
|
||||
m_info.clear();
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue