Read-only mirrors. Development, issues and pull requests are on GitHub.

summaryrefslogtreecommitdiffhomepage
path: root/tests
diff options
context:
space:
mode:
authoroffa2020-01-21 21:04:42 +0100
committerMartin Hořeňovský2020-02-16 15:25:23 +0100
commit06c32862b3d7d20544ba876e590e799667b3afa8 (patch)
tree3f15b5a7abc220c562c353f128c989ba312f782f /tests
parentab520f4e97ad5e9b01c0f08cda868d9690d35aff (diff)
downloadcatch3-06c32862b3d7d20544ba876e590e799667b3afa8.tar.gz
Some refactorings:
- Overrides added - usages of push_back() replaced with emplace_back() - Loop variable made const-refernce - NULL replaced with nullptr - Names used in the declaration and definition unified - size() replaced with empty - Identical cases merged
Diffstat (limited to 'tests')
-rw-r--r--tests/SelfTest/UsageTests/ToStringVector.tests.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/tests/SelfTest/UsageTests/ToStringVector.tests.cpp b/tests/SelfTest/UsageTests/ToStringVector.tests.cpp
index 1283b4a6..5ce2ff75 100644
--- a/tests/SelfTest/UsageTests/ToStringVector.tests.cpp
+++ b/tests/SelfTest/UsageTests/ToStringVector.tests.cpp
@@ -17,9 +17,9 @@ TEST_CASE( "vector<string> -> toString", "[toString][vector]" )
{
std::vector<std::string> vv;
REQUIRE( ::Catch::Detail::stringify(vv) == "{ }" );
- vv.push_back( "hello" );
+ vv.emplace_back( "hello" );
REQUIRE( ::Catch::Detail::stringify(vv) == "{ \"hello\" }" );
- vv.push_back( "world" );
+ vv.emplace_back( "world" );
REQUIRE( ::Catch::Detail::stringify(vv) == "{ \"hello\", \"world\" }" );
}
@@ -83,4 +83,4 @@ TEST_CASE( "array<int, N> -> toString", "[toString][containers][array]" ) {
REQUIRE( Catch::Detail::stringify( oneValue ) == "{ 42 }" );
std::array<int, 2> twoValues = {{ 42, 250 }};
REQUIRE( Catch::Detail::stringify( twoValues ) == "{ 42, 250 }" );
-} \ No newline at end of file
+}