File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -56,6 +56,9 @@ private:
5656 CppUnit ::Test & _shimmed_test ;
5757};
5858
59+ // "Magic number" for when we're not doing allow or deny regex
60+ static constexpr int added_whole_suite = -12345 ;
61+
5962// Add Tests to runner that match user-provided regex.
6063int add_matching_tests_to_runner (CppUnit ::Test * test ,
6164 const std ::string & allow_r_str ,
@@ -72,7 +75,7 @@ int add_matching_tests_to_runner(CppUnit::Test * test,
7275 {
7376 libMesh ::out << test -> getName () << std ::endl ;
7477 runner .addTest (test );
75- return -12345 ;
78+ return added_whole_suite ;
7679 }
7780
7881 if (test -> getChildTestCount () == 0 )
@@ -182,7 +185,7 @@ int main(int argc, char ** argv)
182185
183186 // If we didn't add the whole suite to the runner, we need to clean
184187 // it up ourselves
185- if (n_tests_added != -12345 )
188+ if (n_tests_added != added_whole_suite )
186189 owned_suite .reset (suite );
187190#else
188191 // If no C++11 <regex> just run all the tests.
You can’t perform that action at this time.
0 commit comments