MCPcopy Create free account
hub / github.com/ChaiScript/ChaiScript / parseSpecialTag

Function parseSpecialTag

unittests/catch.hpp:9832–9848  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

9830namespace Catch {
9831
9832 TestCaseInfo::SpecialProperties parseSpecialTag( std::string const& tag ) {
9833 if( startsWith( tag, '.' ) ||
9834 tag == "!hide" )
9835 return TestCaseInfo::IsHidden;
9836 else if( tag == "!throws" )
9837 return TestCaseInfo::Throws;
9838 else if( tag == "!shouldfail" )
9839 return TestCaseInfo::ShouldFail;
9840 else if( tag == "!mayfail" )
9841 return TestCaseInfo::MayFail;
9842 else if( tag == "!nonportable" )
9843 return TestCaseInfo::NonPortable;
9844 else if( tag == "!benchmark" )
9845 return static_cast<TestCaseInfo::SpecialProperties>( TestCaseInfo::Benchmark | TestCaseInfo::IsHidden );
9846 else
9847 return TestCaseInfo::None;
9848 }
9849 bool isReservedTag( std::string const& tag ) {
9850 return parseSpecialTag( tag ) == TestCaseInfo::None && tag.size() > 0 && !std::isalnum( tag[0] );
9851 }

Callers 3

isReservedTagFunction · 0.85
makeTestCaseFunction · 0.85
setTagsFunction · 0.85

Calls 1

startsWithFunction · 0.85

Tested by

no test coverage detected