Fixed test spec parser issue

- multiple specs in a single string, with escapes in each were erroring out
This commit is contained in:
Phil Nash 2017-02-22 07:49:38 +00:00
parent 10dfca34ac
commit d2a59ad37b

View File

@ -97,7 +97,7 @@ namespace Catch {
void addPattern() { void addPattern() {
std::string token = subString(); std::string token = subString();
for( size_t i = 0; i < m_escapeChars.size(); ++i ) for( size_t i = 0; i < m_escapeChars.size(); ++i )
token = token.substr( 0, m_escapeChars[i]-i ) + token.substr( m_escapeChars[i]+1-i ); token = token.substr( 0, m_escapeChars[i]-m_start-i ) + token.substr( m_escapeChars[i]-m_start-i+1 );
m_escapeChars.clear(); m_escapeChars.clear();
if( startsWith( token, "exclude:" ) ) { if( startsWith( token, "exclude:" ) ) {
m_exclusion = true; m_exclusion = true;