@@ -171,7 +171,9 @@ namespace Catch {
171171 m_reporter(CATCH_MOVE (reporter)),
172172 m_lastAssertionInfo{ StringRef (), SourceLineInfo (" " ,0 ), StringRef (), ResultDisposition::Normal },
173173 m_outputRedirect ( makeOutputRedirect( m_reporter->getPreferences ().shouldRedirectStdOut ) ),
174- m_includeSuccessfulResults( m_config->includeSuccessfulResults () || m_reporter->getPreferences().shouldReportAllAssertions )
174+ m_abortAfterXFailedAssertions( m_config->abortAfter () ),
175+ m_includeSuccessfulResults( m_config->includeSuccessfulResults () || m_reporter->getPreferences().shouldReportAllAssertions ),
176+ m_shouldDebugBreak( m_config->shouldDebugBreak () )
175177 {
176178 getCurrentMutableContext ().setResultCapture ( this );
177179 m_reporter->testRunStarting (m_runInfo);
@@ -522,7 +524,7 @@ namespace Catch {
522524 }
523525
524526 bool RunContext::aborting () const {
525- return m_totals.assertions .failed >= static_cast <std:: size_t >(m_config-> abortAfter ()) ;
527+ return m_totals.assertions .failed >= m_abortAfterXFailedAssertions ;
526528 }
527529
528530 void RunContext::runCurrentTest () {
@@ -679,7 +681,7 @@ namespace Catch {
679681
680682 void RunContext::populateReaction ( AssertionReaction& reaction,
681683 bool has_normal_disposition ) {
682- reaction.shouldDebugBreak = m_config-> shouldDebugBreak () ;
684+ reaction.shouldDebugBreak = m_shouldDebugBreak ;
683685 reaction.shouldThrow = aborting () || has_normal_disposition;
684686 }
685687
0 commit comments