diff options
| author | Phil Nash | 2013-09-07 12:07:38 +0100 |
|---|---|---|
| committer | Phil Nash | 2013-09-07 12:07:38 +0100 |
| commit | f7378eebb6ddcc56332ba8addcc29bd076f9b2e5 (patch) | |
| tree | 8609e881ab7e286f9b18512cb80b4d10289ecd73 /include | |
| parent | 04a3364b5a91961563874f41809eb9583b7a9c89 (diff) | |
| download | catch3-f7378eebb6ddcc56332ba8addcc29bd076f9b2e5.tar.gz | |
Fixed string indexing bug
Diffstat (limited to 'include')
| -rw-r--r-- | include/internal/catch_test_case_registry_impl.hpp | 2 | ||||
| -rw-r--r-- | include/internal/catch_version.hpp | 2 | ||||
| -rw-r--r-- | include/reporters/catch_reporter_console.hpp | 4 |
3 files changed, 6 insertions, 2 deletions
diff --git a/include/internal/catch_test_case_registry_impl.hpp b/include/internal/catch_test_case_registry_impl.hpp index a12bb6d5..41714bc8 100644 --- a/include/internal/catch_test_case_registry_impl.hpp +++ b/include/internal/catch_test_case_registry_impl.hpp @@ -111,7 +111,7 @@ namespace Catch { inline std::string extractClassName( std::string const& classOrQualifiedMethodName ) { std::string className = classOrQualifiedMethodName; - if( className[0] == '&' ) + if( startsWith( className, "&" ) ) { std::size_t lastColons = className.rfind( "::" ); std::size_t penultimateColons = className.rfind( "::", lastColons-1 ); diff --git a/include/internal/catch_version.hpp b/include/internal/catch_version.hpp index da70a214..b2311fba 100644 --- a/include/internal/catch_version.hpp +++ b/include/internal/catch_version.hpp @@ -13,7 +13,7 @@ namespace Catch { // These numbers are maintained by a script - Version libraryVersion( 1, 0, 8, "master" ); + Version libraryVersion( 1, 0, 9, "master" ); } #endif // TWOBLUECUBES_CATCH_VERSION_HPP_INCLUDED diff --git a/include/reporters/catch_reporter_console.hpp b/include/reporters/catch_reporter_console.hpp index 8dd8d902..816f4214 100644 --- a/include/reporters/catch_reporter_console.hpp +++ b/include/reporters/catch_reporter_console.hpp @@ -72,6 +72,10 @@ namespace Catch { stream << "Completed in " << _sectionStats.durationInSeconds << "s" << std::endl; m_headerPrinted = false; } + else { + if( m_config->showDurations() == ShowDurations::Always ) + stream << _sectionStats.sectionInfo.name << " completed in " << _sectionStats.durationInSeconds << "s" << std::endl; + } StreamingReporterBase::sectionEnded( _sectionStats ); } |