コード例 #1
0
ファイル: catch_runner_impl.hpp プロジェクト: GlenDC/Catch
 bool testForMissingAssertions( Counts& assertions ) {
     if( assertions.total() != 0 ||
             !m_config->warnAboutMissingAssertions() ||
             m_testCaseTracker->currentSectionHasChildren() )
         return false;
     m_totals.assertions.failed++;
     assertions.failed++;
     return true;
 }
コード例 #2
0
 bool RunContext::testForMissingAssertions(Counts& assertions) {
     if (assertions.total() != 0)
         return false;
     if (!m_config->warnAboutMissingAssertions())
         return false;
     if (m_trackerContext.currentTracker().hasChildren())
         return false;
     m_totals.assertions.failed++;
     assertions.failed++;
     return true;
 }
コード例 #3
0
ファイル: catch_reporter_basic.hpp プロジェクト: tcw321/Catch
 void ReportCounts( const std::string& label, const Counts& counts, const std::string& allPrefix = "All " ) {
     if( counts.passed )
         m_config.stream() << counts.failed << " of " << counts.total() << " " << label << "s failed";
     else
         m_config.stream() << ( counts.failed > 1 ? allPrefix : "" ) << pluralise( counts.failed, label ) << " failed";
 }