Tests hidden with legacy ./ prefix tagged as hidden

This commit is contained in:
Phil Nash 2014-05-20 18:11:23 +01:00
parent fbf3f6f879
commit b43d7703e5

View File

@ -65,20 +65,21 @@ namespace Catch {
enforceNotReservedTag( tag, _lineInfo ); enforceNotReservedTag( tag, _lineInfo );
inTag = false; inTag = false;
if( tag == "hide" || tag == "." ) { if( tag == "hide" || tag == "." )
tags.insert( "hide" );
tags.insert( "." );
isHidden = true; isHidden = true;
} else
else {
tags.insert( tag ); tags.insert( tag );
}
tag.clear(); tag.clear();
} }
else else
tag += c; tag += c;
} }
} }
if( isHidden ) {
tags.insert( "hide" );
tags.insert( "." );
}
TestCaseInfo info( _name, _className, desc, tags, isHidden, _lineInfo ); TestCaseInfo info( _name, _className, desc, tags, isHidden, _lineInfo );
return TestCase( _testCase, info ); return TestCase( _testCase, info );
} }