Approved tag alias tests

This commit is contained in:
Phil Nash
2014-06-30 07:34:27 +01:00
parent 1d210ebd37
commit 061861d940
4 changed files with 154 additions and 5 deletions

View File

@@ -6884,6 +6884,72 @@ PASSED:
with expansion:
true == true
-------------------------------------------------------------------------------
Tag alias can be registered against tag patterns
The same tag alias can only be registered once
-------------------------------------------------------------------------------
TagAliasTests.cpp:<line number>
...............................................................................
TagAliasTests.cpp:<line number>:
PASSED:
CHECK_THAT( what Contains( "[@zzz]" ) )
with expansion:
"error: tag alias, "[@zzz]" already registered.
First seen at file:2
Redefined at file:10" contains: "
[@zzz]"
TagAliasTests.cpp:<line number>:
PASSED:
CHECK_THAT( what Contains( "file" ) )
with expansion:
"error: tag alias, "[@zzz]" already registered.
First seen at file:2
Redefined at file:10" contains:
"file"
TagAliasTests.cpp:<line number>:
PASSED:
CHECK_THAT( what Contains( "2" ) )
with expansion:
"error: tag alias, "[@zzz]" already registered.
First seen at file:2
Redefined at file:10" contains:
"2"
TagAliasTests.cpp:<line number>:
PASSED:
CHECK_THAT( what Contains( "10" ) )
with expansion:
"error: tag alias, "[@zzz]" already registered.
First seen at file:2
Redefined at file:10" contains:
"10"
-------------------------------------------------------------------------------
Tag alias can be registered against tag patterns
Tag aliases must be of the form [@name]
-------------------------------------------------------------------------------
TagAliasTests.cpp:<line number>
...............................................................................
TagAliasTests.cpp:<line number>:
PASSED:
CHECK_THROWS( registry.add( "[no ampersat]", "", Catch::SourceLineInfo( "file", 3 ) ) )
TagAliasTests.cpp:<line number>:
PASSED:
CHECK_THROWS( registry.add( "[the @ is not at the start]", "", Catch::SourceLineInfo( "file", 3 ) ) )
TagAliasTests.cpp:<line number>:
PASSED:
CHECK_THROWS( registry.add( "@no square bracket at start]", "", Catch::SourceLineInfo( "file", 3 ) ) )
TagAliasTests.cpp:<line number>:
PASSED:
CHECK_THROWS( registry.add( "[@no square bracket at end", "", Catch::SourceLineInfo( "file", 3 ) ) )
-------------------------------------------------------------------------------
Anonymous test case 1
-------------------------------------------------------------------------------
@@ -7231,5 +7297,5 @@ with expansion:
true
===============================================================================
124 test cases - 55 failed (715 assertions - 112 failed)
125 test cases - 55 failed (723 assertions - 112 failed)