Progmasoft Git

catch3

Progmasoft Catch3: an independently maintained C++17 test framework with a parallel runner, property checks, snapshots and structured results.

Clonegit clone https://git.progmasoft.com/catch3

Minor tidy up

Commit
49d7ce40e864951a94f83e863335a2538597ff10
Author
Phil Nash ·
Parents
444f4ddc6020

Files · Download .tar.gz

Changes

 include/internal/catch_objc.hpp      | 2 +-
 include/internal/catch_test_spec.h   | 4 ++--
 projects/SelfTest/ConditionTests.cpp | 2 +-
 3 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/include/internal/catch_objc.hpp b/include/internal/catch_objc.hpp
index 1769e55b..a25dd8cd 100644
--- a/include/internal/catch_objc.hpp
+++ b/include/internal/catch_objc.hpp
@@ -72,7 +72,7 @@ namespace Catch {
             return "";
         }        
     }
-    
+
     inline size_t registerTestMethods() {
         size_t noTestMethods = 0;
         int noClasses = objc_getClassList( NULL, 0 );
diff --git a/include/internal/catch_test_spec.h b/include/internal/catch_test_spec.h
index ab1895ac..fa60ce73 100644
--- a/include/internal/catch_test_spec.h
+++ b/include/internal/catch_test_spec.h
@@ -53,11 +53,11 @@ namespace Catch {
                 }
             }
 
-            if( m_stringToMatch[0] == '*' ) {
+            if( startsWith( m_stringToMatch, "*" ) ) {
                 m_stringToMatch = m_stringToMatch.substr( 1 );
                 m_wildcardPosition = (WildcardPosition)( m_wildcardPosition | WildcardAtStart );
             }
-            if( m_stringToMatch[m_stringToMatch.size()-1] == '*' ) {
+            if( endsWith( m_stringToMatch, "*" ) ) {
                 m_stringToMatch = m_stringToMatch.substr( 0, m_stringToMatch.size()-1 );
                 m_wildcardPosition = (WildcardPosition)( m_wildcardPosition | WildcardAtEnd );
             }
diff --git a/projects/SelfTest/ConditionTests.cpp b/projects/SelfTest/ConditionTests.cpp
index e3e3dffe..aebd123e 100644
--- a/projects/SelfTest/ConditionTests.cpp
+++ b/projects/SelfTest/ConditionTests.cpp
@@ -204,7 +204,7 @@ TEST_CASE(  "./succeeding/conditions/int literals",
 
 // Disable warnings about sign conversions for the next two tests
 // (as we are deliberately invoking them)
-// - Current only disabled for GCC/ LLVM. Should add VC++ too
+// - Currently only disabled for GCC/ LLVM. Should add VC++ too
 #ifdef  __GNUC__
 #pragma GCC diagnostic push
 #pragma GCC diagnostic ignored "-Wsign-compare"