MCPcopy Create free account
hub / github.com/InteractiveComputerGraphics/TriangleMeshDistance / expandAliases

Method expandAliases

tests/catch.hpp:11328–11339  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

11326 }
11327
11328 std::string TagAliasRegistry::expandAliases( std::string const& unexpandedTestSpec ) const {
11329 std::string expandedTestSpec = unexpandedTestSpec;
11330 for( auto const& registryKvp : m_registry ) {
11331 std::size_t pos = expandedTestSpec.find( registryKvp.first );
11332 if( pos != std::string::npos ) {
11333 expandedTestSpec = expandedTestSpec.substr( 0, pos ) +
11334 registryKvp.second.tag +
11335 expandedTestSpec.substr( pos + registryKvp.first.size() );
11336 }
11337 }
11338 return expandedTestSpec;
11339 }
11340
11341 void TagAliasRegistry::add( std::string const& alias, std::string const& tag, SourceLineInfo const& lineInfo ) {
11342 CATCH_ENFORCE( startsWith(alias, "[@") && endsWith(alias, ']'),

Callers 1

catch.hppFile · 0.80

Calls 3

findMethod · 0.80
substrMethod · 0.80
sizeMethod · 0.80

Tested by

no test coverage detected