diff --git a/projects/SelfTest/Baselines/console.std.approved.txt b/projects/SelfTest/Baselines/console.std.approved.txt index a97b7a3a..5c9783cb 100644 --- a/projects/SelfTest/Baselines/console.std.approved.txt +++ b/projects/SelfTest/Baselines/console.std.approved.txt @@ -759,7 +759,7 @@ warning: error ------------------------------------------------------------------------------- -A failing expression with a non streamable type is still captured[failing] +A failing expression with a non streamable type is still captured ------------------------------------------------------------------------------- TrickyTests.cpp: ............................................................................... @@ -775,7 +775,7 @@ with expansion: {?} == {?} ------------------------------------------------------------------------------- -string literals of different sizes can be compared[failing] +string literals of different sizes can be compared ------------------------------------------------------------------------------- TrickyTests.cpp: ............................................................................... @@ -786,6 +786,6 @@ with expansion: "first" == "second" =============================================================================== -test cases: 148 | 109 passed | 38 failed | 1 failed as expected -assertions: 739 | 647 passed | 79 failed | 13 failed as expected +test cases: 149 | 110 passed | 38 failed | 1 failed as expected +assertions: 751 | 659 passed | 79 failed | 13 failed as expected diff --git a/projects/SelfTest/Baselines/console.sw.approved.txt b/projects/SelfTest/Baselines/console.sw.approved.txt index 7f6be8ec..682a2ac7 100644 --- a/projects/SelfTest/Baselines/console.sw.approved.txt +++ b/projects/SelfTest/Baselines/console.sw.approved.txt @@ -4518,6 +4518,120 @@ with expansion: five six" +------------------------------------------------------------------------------- +replaceInPlace + replace single char +------------------------------------------------------------------------------- +TestMain.cpp: +............................................................................... + +TestMain.cpp:: +PASSED: + CHECK( replaceInPlace( letters, "b", "z" ) ) +with expansion: + true + +TestMain.cpp:: +PASSED: + CHECK( letters == "azcdefcg" ) +with expansion: + "azcdefcg" == "azcdefcg" + +------------------------------------------------------------------------------- +replaceInPlace + replace two chars +------------------------------------------------------------------------------- +TestMain.cpp: +............................................................................... + +TestMain.cpp:: +PASSED: + CHECK( replaceInPlace( letters, "c", "z" ) ) +with expansion: + true + +TestMain.cpp:: +PASSED: + CHECK( letters == "abzdefzg" ) +with expansion: + "abzdefzg" == "abzdefzg" + +------------------------------------------------------------------------------- +replaceInPlace + replace first char +------------------------------------------------------------------------------- +TestMain.cpp: +............................................................................... + +TestMain.cpp:: +PASSED: + CHECK( replaceInPlace( letters, "a", "z" ) ) +with expansion: + true + +TestMain.cpp:: +PASSED: + CHECK( letters == "zbcdefcg" ) +with expansion: + "zbcdefcg" == "zbcdefcg" + +------------------------------------------------------------------------------- +replaceInPlace + replace last char +------------------------------------------------------------------------------- +TestMain.cpp: +............................................................................... + +TestMain.cpp:: +PASSED: + CHECK( replaceInPlace( letters, "g", "z" ) ) +with expansion: + true + +TestMain.cpp:: +PASSED: + CHECK( letters == "abcdefcz" ) +with expansion: + "abcdefcz" == "abcdefcz" + +------------------------------------------------------------------------------- +replaceInPlace + replace all chars +------------------------------------------------------------------------------- +TestMain.cpp: +............................................................................... + +TestMain.cpp:: +PASSED: + CHECK( replaceInPlace( letters, letters, "replaced" ) ) +with expansion: + true + +TestMain.cpp:: +PASSED: + CHECK( letters == "replaced" ) +with expansion: + "replaced" == "replaced" + +------------------------------------------------------------------------------- +replaceInPlace + replace no chars +------------------------------------------------------------------------------- +TestMain.cpp: +............................................................................... + +TestMain.cpp:: +PASSED: + CHECK_FALSE( replaceInPlace( letters, "x", "z" ) ) +with expansion: + !false + +TestMain.cpp:: +PASSED: + CHECK( letters == letters ) +with expansion: + "abcdefcg" == "abcdefcg" + hello hello ------------------------------------------------------------------------------- @@ -5604,7 +5718,7 @@ warning: No assertions in test case 'Where the LHS is not a simple value[failing]' ------------------------------------------------------------------------------- -A failing expression with a non streamable type is still captured[failing] +A failing expression with a non streamable type is still captured ------------------------------------------------------------------------------- TrickyTests.cpp: ............................................................................... @@ -5620,7 +5734,7 @@ with expansion: {?} == {?} ------------------------------------------------------------------------------- -string literals of different sizes can be compared[failing] +string literals of different sizes can be compared ------------------------------------------------------------------------------- TrickyTests.cpp: ............................................................................... @@ -7683,6 +7797,6 @@ with expansion: true =============================================================================== -test cases: 148 | 93 passed | 54 failed | 1 failed as expected -assertions: 759 | 647 passed | 99 failed | 13 failed as expected +test cases: 149 | 94 passed | 54 failed | 1 failed as expected +assertions: 771 | 659 passed | 99 failed | 13 failed as expected diff --git a/projects/SelfTest/Baselines/junit.sw.approved.txt b/projects/SelfTest/Baselines/junit.sw.approved.txt index 7529791d..b65529c7 100644 --- a/projects/SelfTest/Baselines/junit.sw.approved.txt +++ b/projects/SelfTest/Baselines/junit.sw.approved.txt @@ -1,5 +1,5 @@ - + @@ -485,6 +485,12 @@ MiscTests.cpp: + + + + + + hello @@ -496,7 +502,7 @@ hello - + TrickyTests.cpp: @@ -504,7 +510,7 @@ TrickyTests.cpp: TrickyTests.cpp: - + TrickyTests.cpp: diff --git a/projects/SelfTest/Baselines/xml.sw.approved.txt b/projects/SelfTest/Baselines/xml.sw.approved.txt index 612ed0bf..54ac8624 100644 --- a/projects/SelfTest/Baselines/xml.sw.approved.txt +++ b/projects/SelfTest/Baselines/xml.sw.approved.txt @@ -4714,6 +4714,123 @@ four" + +
+ + + replaceInPlace( letters, "b", "z" ) + + + true + + + + + letters == "azcdefcg" + + + "azcdefcg" == "azcdefcg" + + + +
+
+ + + replaceInPlace( letters, "c", "z" ) + + + true + + + + + letters == "abzdefzg" + + + "abzdefzg" == "abzdefzg" + + + +
+
+ + + replaceInPlace( letters, "a", "z" ) + + + true + + + + + letters == "zbcdefcg" + + + "zbcdefcg" == "zbcdefcg" + + + +
+
+ + + replaceInPlace( letters, "g", "z" ) + + + true + + + + + letters == "abcdefcz" + + + "abcdefcz" == "abcdefcz" + + + +
+
+ + + replaceInPlace( letters, letters, "replaced" ) + + + true + + + + + letters == "replaced" + + + "replaced" == "replaced" + + + +
+
+ + + !replaceInPlace( letters, "x", "z" ) + + + !false + + + + + letters == letters + + + "abcdefcg" == "abcdefcg" + + + +
+ +
@@ -5774,7 +5891,7 @@ there"
- + &o1 == &o2 @@ -5793,7 +5910,7 @@ there" - + std::string( "first" ) == "second" @@ -7950,7 +8067,7 @@ there" - + - +