Add trim for StringRef

This commit is contained in:
Martin Hořeňovský
2019-09-07 11:31:00 +02:00
parent b77ab74b72
commit f2c2711bdc
8 changed files with 106 additions and 5 deletions

View File

@@ -11854,6 +11854,46 @@ Message from section two
"There is no extra whitespace here"
</Expanded>
</Expression>
<Expression success="true" type="REQUIRE" filename="projects/<exe-name>/IntrospectiveTests/StringManip.tests.cpp" >
<Original>
trim(StringRef(no_whitespace)) == StringRef(no_whitespace)
</Original>
<Expanded>
There is no extra whitespace here
==
There is no extra whitespace here
</Expanded>
</Expression>
<Expression success="true" type="REQUIRE" filename="projects/<exe-name>/IntrospectiveTests/StringManip.tests.cpp" >
<Original>
trim(StringRef(leading_whitespace)) == StringRef(no_whitespace)
</Original>
<Expanded>
There is no extra whitespace here
==
There is no extra whitespace here
</Expanded>
</Expression>
<Expression success="true" type="REQUIRE" filename="projects/<exe-name>/IntrospectiveTests/StringManip.tests.cpp" >
<Original>
trim(StringRef(trailing_whitespace)) == StringRef(no_whitespace)
</Original>
<Expanded>
There is no extra whitespace here
==
There is no extra whitespace here
</Expanded>
</Expression>
<Expression success="true" type="REQUIRE" filename="projects/<exe-name>/IntrospectiveTests/StringManip.tests.cpp" >
<Original>
trim(StringRef(whitespace_at_both_ends)) == StringRef(no_whitespace)
</Original>
<Expanded>
There is no extra whitespace here
==
There is no extra whitespace here
</Expanded>
</Expression>
<OverallResult success="true"/>
</TestCase>
<TestCase name="Unexpected exceptions can be translated" tags="[!throws][.][failing]" filename="projects/<exe-name>/UsageTests/Exception.tests.cpp" >
@@ -14821,7 +14861,7 @@ loose text artifact
</Section>
<OverallResult success="true"/>
</TestCase>
<OverallResults successes="1406" failures="149" expectedFailures="21"/>
<OverallResults successes="1410" failures="149" expectedFailures="21"/>
</Group>
<OverallResults successes="1406" failures="148" expectedFailures="21"/>
<OverallResults successes="1410" failures="148" expectedFailures="21"/>
</Catch>