Fixes #1766: Catch terminates when parsing invalid test name
This commit is contained in:
parent
01ef7076f5
commit
84856844e1
12 changed files with 88 additions and 28 deletions
|
@ -49,9 +49,15 @@ namespace Catch {
|
|||
if( !line.empty() && !startsWith( line, '#' ) ) {
|
||||
if( !startsWith( line, '"' ) )
|
||||
line = '"' + line + '"';
|
||||
config.testsOrTags.push_back( line + ',' );
|
||||
config.testsOrTags.push_back( line );
|
||||
config.testsOrTags.push_back( "," );
|
||||
|
||||
}
|
||||
}
|
||||
//Remove comma in the end
|
||||
if(!config.testsOrTags.empty())
|
||||
config.testsOrTags.erase( config.testsOrTags.end()-1 );
|
||||
|
||||
return ParserResult::ok( ParseResultType::Matched );
|
||||
};
|
||||
auto const setTestOrder = [&]( std::string const& order ) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue