diff --git a/projects/SelfTest/Baselines/compact.sw.approved.txt b/projects/SelfTest/Baselines/compact.sw.approved.txt index 7c00f483b2..89ebdfb1b5 100644 --- a/projects/SelfTest/Baselines/compact.sw.approved.txt +++ b/projects/SelfTest/Baselines/compact.sw.approved.txt @@ -155,18 +155,36 @@ Class.tests.cpp:: passed: Template_Fixture_2::m_a.size() Class.tests.cpp:: passed: Template_Fixture_2::m_a.size() == 0 for: 0 == 0 Class.tests.cpp:: passed: Template_Fixture_2::m_a.size() == 0 for: 0 == 0 Class.tests.cpp:: passed: Template_Fixture_2::m_a.size() == 0 for: 0 == 0 +Class.tests.cpp:: failed: Template_Fixture_2{}.m_a.size() < 2 for: 6 < 2 +Class.tests.cpp:: failed: Template_Fixture_2{}.m_a.size() < 2 for: 2 < 2 +Class.tests.cpp:: failed: Template_Fixture_2{}.m_a.size() < 2 for: 6 < 2 +Class.tests.cpp:: failed: Template_Fixture_2{}.m_a.size() < 2 for: 2 < 2 +Class.tests.cpp:: passed: Template_Fixture_2{}.m_a.size() >= 2 for: 6 >= 2 +Class.tests.cpp:: passed: Template_Fixture_2{}.m_a.size() >= 2 for: 2 >= 2 +Class.tests.cpp:: passed: Template_Fixture_2{}.m_a.size() >= 2 for: 6 >= 2 +Class.tests.cpp:: passed: Template_Fixture_2{}.m_a.size() >= 2 for: 2 >= 2 Class.tests.cpp:: failed: Template_Fixture::m_a == 2 for: 1.0 == 2 Class.tests.cpp:: failed: Template_Fixture::m_a == 2 for: 1.0f == 2 Class.tests.cpp:: failed: Template_Fixture::m_a == 2 for: 1 == 2 Class.tests.cpp:: passed: Template_Fixture::m_a == 1 for: 1.0 == 1 Class.tests.cpp:: passed: Template_Fixture::m_a == 1 for: 1.0f == 1 Class.tests.cpp:: passed: Template_Fixture::m_a == 1 for: 1 == 1 +Class.tests.cpp:: failed: Nttp_Fixture::value == 0 for: 1 == 0 +Class.tests.cpp:: failed: Nttp_Fixture::value == 0 for: 3 == 0 +Class.tests.cpp:: failed: Nttp_Fixture::value == 0 for: 6 == 0 +Class.tests.cpp:: passed: Nttp_Fixture::value > 0 for: 1 > 0 +Class.tests.cpp:: passed: Nttp_Fixture::value > 0 for: 3 > 0 +Class.tests.cpp:: passed: Nttp_Fixture::value > 0 for: 6 > 0 Class.tests.cpp:: failed: m_a == 2 for: 1 == 2 Class.tests.cpp:: passed: m_a == 1 for: 1 == 1 Misc.tests.cpp:: passed: x.size() == 0 for: 0 == 0 Misc.tests.cpp:: passed: x.size() == 0 for: 0 == 0 Misc.tests.cpp:: passed: x.size() == 0 for: 0 == 0 Misc.tests.cpp:: passed: x.size() == 0 for: 0 == 0 +Misc.tests.cpp:: passed: x.size() > 0 for: 42 > 0 +Misc.tests.cpp:: passed: x.size() > 0 for: 9 > 0 +Misc.tests.cpp:: passed: x.size() > 0 for: 42 > 0 +Misc.tests.cpp:: passed: x.size() > 0 for: 9 > 0 Approx.tests.cpp:: passed: d == 1.23_a for: 1.23 == Approx( 1.23 ) Approx.tests.cpp:: passed: d != 1.22_a for: 1.23 != Approx( 1.22 ) Approx.tests.cpp:: passed: -d == -1.23_a for: -1.23 == Approx( -1.23 ) @@ -1126,6 +1144,74 @@ Misc.tests.cpp:: passed: v.size() == 5 for: 5 == 5 Misc.tests.cpp:: passed: v.capacity() >= 5 for: 5 >= 5 Misc.tests.cpp:: passed: v.size() == 5 for: 5 == 5 Misc.tests.cpp:: passed: v.capacity() >= 5 for: 5 >= 5 +Misc.tests.cpp:: passed: v.size() == V for: 6 == 6 +Misc.tests.cpp:: passed: v.capacity() >= V for: 6 >= 6 +Misc.tests.cpp:: passed: v.size() == 2 * V for: 12 == 12 +Misc.tests.cpp:: passed: v.capacity() >= 2 * V for: 12 >= 12 +Misc.tests.cpp:: passed: v.size() == V for: 6 == 6 +Misc.tests.cpp:: passed: v.capacity() >= V for: 6 >= 6 +Misc.tests.cpp:: passed: v.size() == 0 for: 0 == 0 +Misc.tests.cpp:: passed: v.capacity() >= V for: 6 >= 6 +Misc.tests.cpp:: passed: v.capacity() == 0 for: 0 == 0 +Misc.tests.cpp:: passed: v.size() == V for: 6 == 6 +Misc.tests.cpp:: passed: v.capacity() >= V for: 6 >= 6 +Misc.tests.cpp:: passed: v.size() == V for: 6 == 6 +Misc.tests.cpp:: passed: v.capacity() >= 2 * V for: 12 >= 12 +Misc.tests.cpp:: passed: v.size() == V for: 6 == 6 +Misc.tests.cpp:: passed: v.capacity() >= V for: 6 >= 6 +Misc.tests.cpp:: passed: v.size() == V for: 6 == 6 +Misc.tests.cpp:: passed: v.capacity() >= V for: 6 >= 6 +Misc.tests.cpp:: passed: v.size() == V for: 4 == 4 +Misc.tests.cpp:: passed: v.capacity() >= V for: 4 >= 4 +Misc.tests.cpp:: passed: v.size() == 2 * V for: 8 == 8 +Misc.tests.cpp:: passed: v.capacity() >= 2 * V for: 8 >= 8 +Misc.tests.cpp:: passed: v.size() == V for: 4 == 4 +Misc.tests.cpp:: passed: v.capacity() >= V for: 4 >= 4 +Misc.tests.cpp:: passed: v.size() == 0 for: 0 == 0 +Misc.tests.cpp:: passed: v.capacity() >= V for: 4 >= 4 +Misc.tests.cpp:: passed: v.capacity() == 0 for: 0 == 0 +Misc.tests.cpp:: passed: v.size() == V for: 4 == 4 +Misc.tests.cpp:: passed: v.capacity() >= V for: 4 >= 4 +Misc.tests.cpp:: passed: v.size() == V for: 4 == 4 +Misc.tests.cpp:: passed: v.capacity() >= 2 * V for: 8 >= 8 +Misc.tests.cpp:: passed: v.size() == V for: 4 == 4 +Misc.tests.cpp:: passed: v.capacity() >= V for: 4 >= 4 +Misc.tests.cpp:: passed: v.size() == V for: 4 == 4 +Misc.tests.cpp:: passed: v.capacity() >= V for: 4 >= 4 +Misc.tests.cpp:: passed: v.size() == V for: 5 == 5 +Misc.tests.cpp:: passed: v.capacity() >= V for: 5 >= 5 +Misc.tests.cpp:: passed: v.size() == 2 * V for: 10 == 10 +Misc.tests.cpp:: passed: v.capacity() >= 2 * V for: 10 >= 10 +Misc.tests.cpp:: passed: v.size() == V for: 5 == 5 +Misc.tests.cpp:: passed: v.capacity() >= V for: 5 >= 5 +Misc.tests.cpp:: passed: v.size() == 0 for: 0 == 0 +Misc.tests.cpp:: passed: v.capacity() >= V for: 5 >= 5 +Misc.tests.cpp:: passed: v.capacity() == 0 for: 0 == 0 +Misc.tests.cpp:: passed: v.size() == V for: 5 == 5 +Misc.tests.cpp:: passed: v.capacity() >= V for: 5 >= 5 +Misc.tests.cpp:: passed: v.size() == V for: 5 == 5 +Misc.tests.cpp:: passed: v.capacity() >= 2 * V for: 10 >= 10 +Misc.tests.cpp:: passed: v.size() == V for: 5 == 5 +Misc.tests.cpp:: passed: v.capacity() >= V for: 5 >= 5 +Misc.tests.cpp:: passed: v.size() == V for: 5 == 5 +Misc.tests.cpp:: passed: v.capacity() >= V for: 5 >= 5 +Misc.tests.cpp:: passed: v.size() == V for: 15 == 15 +Misc.tests.cpp:: passed: v.capacity() >= V for: 15 >= 15 +Misc.tests.cpp:: passed: v.size() == 2 * V for: 30 == 30 +Misc.tests.cpp:: passed: v.capacity() >= 2 * V for: 30 >= 30 +Misc.tests.cpp:: passed: v.size() == V for: 15 == 15 +Misc.tests.cpp:: passed: v.capacity() >= V for: 15 >= 15 +Misc.tests.cpp:: passed: v.size() == 0 for: 0 == 0 +Misc.tests.cpp:: passed: v.capacity() >= V for: 15 >= 15 +Misc.tests.cpp:: passed: v.capacity() == 0 for: 0 == 0 +Misc.tests.cpp:: passed: v.size() == V for: 15 == 15 +Misc.tests.cpp:: passed: v.capacity() >= V for: 15 >= 15 +Misc.tests.cpp:: passed: v.size() == V for: 15 == 15 +Misc.tests.cpp:: passed: v.capacity() >= 2 * V for: 30 >= 30 +Misc.tests.cpp:: passed: v.size() == V for: 15 == 15 +Misc.tests.cpp:: passed: v.capacity() >= V for: 15 >= 15 +Misc.tests.cpp:: passed: v.size() == V for: 15 == 15 +Misc.tests.cpp:: passed: v.capacity() >= V for: 15 >= 15 VariadicMacros.tests.cpp:: passed: with 1 message: 'no assertions' Tricky.tests.cpp:: passed: 0x == bit30and31 for: 3221225472 (0x) == 3221225472 Message.tests.cpp:: failed - but was ok: 1 == 2 @@ -1543,5 +1629,5 @@ Misc.tests.cpp:: passed: v.size() == 5 for: 5 == 5 Misc.tests.cpp:: passed: v.capacity() >= 5 for: 5 >= 5 Misc.tests.cpp:: passed: Misc.tests.cpp:: passed: -Failed 79 test cases, failed 141 assertions. +Failed 86 test cases, failed 148 assertions. diff --git a/projects/SelfTest/Baselines/console.std.approved.txt b/projects/SelfTest/Baselines/console.std.approved.txt index aa991bd403..5f8e036272 100644 --- a/projects/SelfTest/Baselines/console.std.approved.txt +++ b/projects/SelfTest/Baselines/console.std.approved.txt @@ -163,6 +163,54 @@ Class.tests.cpp:: FAILED: with expansion: 0 == 1 +------------------------------------------------------------------------------- +A TEMPLATE_PRODUCT_TEST_CASE_METHOD_SIG based test run that fails - +Template_Foo_2 +------------------------------------------------------------------------------- +Class.tests.cpp: +............................................................................... + +Class.tests.cpp:: FAILED: + REQUIRE( Template_Fixture_2{}.m_a.size() < 2 ) +with expansion: + 6 < 2 + +------------------------------------------------------------------------------- +A TEMPLATE_PRODUCT_TEST_CASE_METHOD_SIG based test run that fails - +Template_Foo_2 +------------------------------------------------------------------------------- +Class.tests.cpp: +............................................................................... + +Class.tests.cpp:: FAILED: + REQUIRE( Template_Fixture_2{}.m_a.size() < 2 ) +with expansion: + 2 < 2 + +------------------------------------------------------------------------------- +A TEMPLATE_PRODUCT_TEST_CASE_METHOD_SIG based test run that fails - std::array + +------------------------------------------------------------------------------- +Class.tests.cpp: +............................................................................... + +Class.tests.cpp:: FAILED: + REQUIRE( Template_Fixture_2{}.m_a.size() < 2 ) +with expansion: + 6 < 2 + +------------------------------------------------------------------------------- +A TEMPLATE_PRODUCT_TEST_CASE_METHOD_SIG based test run that fails - std::array + +------------------------------------------------------------------------------- +Class.tests.cpp: +............................................................................... + +Class.tests.cpp:: FAILED: + REQUIRE( Template_Fixture_2{}.m_a.size() < 2 ) +with expansion: + 2 < 2 + ------------------------------------------------------------------------------- A TEMPLATE_TEST_CASE_METHOD based test run that fails - double ------------------------------------------------------------------------------- @@ -196,6 +244,39 @@ Class.tests.cpp:: FAILED: with expansion: 1 == 2 +------------------------------------------------------------------------------- +A TEMPLATE_TEST_CASE_METHOD_SIG based test run that fails - 1 +------------------------------------------------------------------------------- +Class.tests.cpp: +............................................................................... + +Class.tests.cpp:: FAILED: + REQUIRE( Nttp_Fixture::value == 0 ) +with expansion: + 1 == 0 + +------------------------------------------------------------------------------- +A TEMPLATE_TEST_CASE_METHOD_SIG based test run that fails - 3 +------------------------------------------------------------------------------- +Class.tests.cpp: +............................................................................... + +Class.tests.cpp:: FAILED: + REQUIRE( Nttp_Fixture::value == 0 ) +with expansion: + 3 == 0 + +------------------------------------------------------------------------------- +A TEMPLATE_TEST_CASE_METHOD_SIG based test run that fails - 6 +------------------------------------------------------------------------------- +Class.tests.cpp: +............................................................................... + +Class.tests.cpp:: FAILED: + REQUIRE( Nttp_Fixture::value == 0 ) +with expansion: + 6 == 0 + ------------------------------------------------------------------------------- A TEST_CASE_METHOD based test run that fails ------------------------------------------------------------------------------- @@ -1299,6 +1380,6 @@ due to unexpected exception with message: Why would you throw a std::string? =============================================================================== -test cases: 267 | 200 passed | 63 failed | 4 failed as expected -assertions: 1453 | 1308 passed | 124 failed | 21 failed as expected +test cases: 289 | 215 passed | 70 failed | 4 failed as expected +assertions: 1539 | 1387 passed | 131 failed | 21 failed as expected diff --git a/projects/SelfTest/Baselines/console.sw.approved.txt b/projects/SelfTest/Baselines/console.sw.approved.txt index cca937fe2a..cd65bc1709 100644 --- a/projects/SelfTest/Baselines/console.sw.approved.txt +++ b/projects/SelfTest/Baselines/console.sw.approved.txt @@ -1179,6 +1179,102 @@ Class.tests.cpp:: PASSED: with expansion: 0 == 0 +------------------------------------------------------------------------------- +A TEMPLATE_PRODUCT_TEST_CASE_METHOD_SIG based test run that fails - +Template_Foo_2 +------------------------------------------------------------------------------- +Class.tests.cpp: +............................................................................... + +Class.tests.cpp:: FAILED: + REQUIRE( Template_Fixture_2{}.m_a.size() < 2 ) +with expansion: + 6 < 2 + +------------------------------------------------------------------------------- +A TEMPLATE_PRODUCT_TEST_CASE_METHOD_SIG based test run that fails - +Template_Foo_2 +------------------------------------------------------------------------------- +Class.tests.cpp: +............................................................................... + +Class.tests.cpp:: FAILED: + REQUIRE( Template_Fixture_2{}.m_a.size() < 2 ) +with expansion: + 2 < 2 + +------------------------------------------------------------------------------- +A TEMPLATE_PRODUCT_TEST_CASE_METHOD_SIG based test run that fails - std::array + +------------------------------------------------------------------------------- +Class.tests.cpp: +............................................................................... + +Class.tests.cpp:: FAILED: + REQUIRE( Template_Fixture_2{}.m_a.size() < 2 ) +with expansion: + 6 < 2 + +------------------------------------------------------------------------------- +A TEMPLATE_PRODUCT_TEST_CASE_METHOD_SIG based test run that fails - std::array + +------------------------------------------------------------------------------- +Class.tests.cpp: +............................................................................... + +Class.tests.cpp:: FAILED: + REQUIRE( Template_Fixture_2{}.m_a.size() < 2 ) +with expansion: + 2 < 2 + +------------------------------------------------------------------------------- +A TEMPLATE_PRODUCT_TEST_CASE_METHOD_SIG based test run that succeeds - +Template_Foo_2 +------------------------------------------------------------------------------- +Class.tests.cpp: +............................................................................... + +Class.tests.cpp:: PASSED: + REQUIRE( Template_Fixture_2{}.m_a.size() >= 2 ) +with expansion: + 6 >= 2 + +------------------------------------------------------------------------------- +A TEMPLATE_PRODUCT_TEST_CASE_METHOD_SIG based test run that succeeds - +Template_Foo_2 +------------------------------------------------------------------------------- +Class.tests.cpp: +............................................................................... + +Class.tests.cpp:: PASSED: + REQUIRE( Template_Fixture_2{}.m_a.size() >= 2 ) +with expansion: + 2 >= 2 + +------------------------------------------------------------------------------- +A TEMPLATE_PRODUCT_TEST_CASE_METHOD_SIG based test run that succeeds - std:: +array +------------------------------------------------------------------------------- +Class.tests.cpp: +............................................................................... + +Class.tests.cpp:: PASSED: + REQUIRE( Template_Fixture_2{}.m_a.size() >= 2 ) +with expansion: + 6 >= 2 + +------------------------------------------------------------------------------- +A TEMPLATE_PRODUCT_TEST_CASE_METHOD_SIG based test run that succeeds - std:: +array +------------------------------------------------------------------------------- +Class.tests.cpp: +............................................................................... + +Class.tests.cpp:: PASSED: + REQUIRE( Template_Fixture_2{}.m_a.size() >= 2 ) +with expansion: + 2 >= 2 + ------------------------------------------------------------------------------- A TEMPLATE_TEST_CASE_METHOD based test run that fails - double ------------------------------------------------------------------------------- @@ -1245,6 +1341,72 @@ Class.tests.cpp:: PASSED: with expansion: 1 == 1 +------------------------------------------------------------------------------- +A TEMPLATE_TEST_CASE_METHOD_SIG based test run that fails - 1 +------------------------------------------------------------------------------- +Class.tests.cpp: +............................................................................... + +Class.tests.cpp:: FAILED: + REQUIRE( Nttp_Fixture::value == 0 ) +with expansion: + 1 == 0 + +------------------------------------------------------------------------------- +A TEMPLATE_TEST_CASE_METHOD_SIG based test run that fails - 3 +------------------------------------------------------------------------------- +Class.tests.cpp: +............................................................................... + +Class.tests.cpp:: FAILED: + REQUIRE( Nttp_Fixture::value == 0 ) +with expansion: + 3 == 0 + +------------------------------------------------------------------------------- +A TEMPLATE_TEST_CASE_METHOD_SIG based test run that fails - 6 +------------------------------------------------------------------------------- +Class.tests.cpp: +............................................................................... + +Class.tests.cpp:: FAILED: + REQUIRE( Nttp_Fixture::value == 0 ) +with expansion: + 6 == 0 + +------------------------------------------------------------------------------- +A TEMPLATE_TEST_CASE_METHOD_SIG based test run that succeeds - 1 +------------------------------------------------------------------------------- +Class.tests.cpp: +............................................................................... + +Class.tests.cpp:: PASSED: + REQUIRE( Nttp_Fixture::value > 0 ) +with expansion: + 1 > 0 + +------------------------------------------------------------------------------- +A TEMPLATE_TEST_CASE_METHOD_SIG based test run that succeeds - 3 +------------------------------------------------------------------------------- +Class.tests.cpp: +............................................................................... + +Class.tests.cpp:: PASSED: + REQUIRE( Nttp_Fixture::value > 0 ) +with expansion: + 3 > 0 + +------------------------------------------------------------------------------- +A TEMPLATE_TEST_CASE_METHOD_SIG based test run that succeeds - 6 +------------------------------------------------------------------------------- +Class.tests.cpp: +............................................................................... + +Class.tests.cpp:: PASSED: + REQUIRE( Nttp_Fixture::value > 0 ) +with expansion: + 6 > 0 + ------------------------------------------------------------------------------- A TEST_CASE_METHOD based test run that fails ------------------------------------------------------------------------------- @@ -1311,6 +1473,50 @@ Misc.tests.cpp:: PASSED: with expansion: 0 == 0 +------------------------------------------------------------------------------- +A Template product test case with array signature - Bar +------------------------------------------------------------------------------- +Misc.tests.cpp: +............................................................................... + +Misc.tests.cpp:: PASSED: + REQUIRE( x.size() > 0 ) +with expansion: + 42 > 0 + +------------------------------------------------------------------------------- +A Template product test case with array signature - Bar +------------------------------------------------------------------------------- +Misc.tests.cpp: +............................................................................... + +Misc.tests.cpp:: PASSED: + REQUIRE( x.size() > 0 ) +with expansion: + 9 > 0 + +------------------------------------------------------------------------------- +A Template product test case with array signature - std::array +------------------------------------------------------------------------------- +Misc.tests.cpp: +............................................................................... + +Misc.tests.cpp:: PASSED: + REQUIRE( x.size() > 0 ) +with expansion: + 42 > 0 + +------------------------------------------------------------------------------- +A Template product test case with array signature - std::array +------------------------------------------------------------------------------- +Misc.tests.cpp: +............................................................................... + +Misc.tests.cpp:: PASSED: + REQUIRE( x.size() > 0 ) +with expansion: + 9 > 0 + ------------------------------------------------------------------------------- A comparison that uses literals instead of the normal constructor ------------------------------------------------------------------------------- @@ -8274,6 +8480,586 @@ Misc.tests.cpp:: PASSED: with expansion: 5 >= 5 +------------------------------------------------------------------------------- +TemplateTestSig: vectors can be sized and resized - (std::tuple), 6 +------------------------------------------------------------------------------- +Misc.tests.cpp: +............................................................................... + +Misc.tests.cpp:: PASSED: + REQUIRE( v.size() == V ) +with expansion: + 6 == 6 + +Misc.tests.cpp:: PASSED: + REQUIRE( v.capacity() >= V ) +with expansion: + 6 >= 6 + +------------------------------------------------------------------------------- +TemplateTestSig: vectors can be sized and resized - (std::tuple), 6 + resizing bigger changes size and capacity +------------------------------------------------------------------------------- +Misc.tests.cpp: +............................................................................... + +Misc.tests.cpp:: PASSED: + REQUIRE( v.size() == 2 * V ) +with expansion: + 12 == 12 + +Misc.tests.cpp:: PASSED: + REQUIRE( v.capacity() >= 2 * V ) +with expansion: + 12 >= 12 + +------------------------------------------------------------------------------- +TemplateTestSig: vectors can be sized and resized - (std::tuple), 6 +------------------------------------------------------------------------------- +Misc.tests.cpp: +............................................................................... + +Misc.tests.cpp:: PASSED: + REQUIRE( v.size() == V ) +with expansion: + 6 == 6 + +Misc.tests.cpp:: PASSED: + REQUIRE( v.capacity() >= V ) +with expansion: + 6 >= 6 + +------------------------------------------------------------------------------- +TemplateTestSig: vectors can be sized and resized - (std::tuple), 6 + resizing smaller changes size but not capacity +------------------------------------------------------------------------------- +Misc.tests.cpp: +............................................................................... + +Misc.tests.cpp:: PASSED: + REQUIRE( v.size() == 0 ) +with expansion: + 0 == 0 + +Misc.tests.cpp:: PASSED: + REQUIRE( v.capacity() >= V ) +with expansion: + 6 >= 6 + +------------------------------------------------------------------------------- +TemplateTestSig: vectors can be sized and resized - (std::tuple), 6 + resizing smaller changes size but not capacity + We can use the 'swap trick' to reset the capacity +------------------------------------------------------------------------------- +Misc.tests.cpp: +............................................................................... + +Misc.tests.cpp:: PASSED: + REQUIRE( v.capacity() == 0 ) +with expansion: + 0 == 0 + +------------------------------------------------------------------------------- +TemplateTestSig: vectors can be sized and resized - (std::tuple), 6 +------------------------------------------------------------------------------- +Misc.tests.cpp: +............................................................................... + +Misc.tests.cpp:: PASSED: + REQUIRE( v.size() == V ) +with expansion: + 6 == 6 + +Misc.tests.cpp:: PASSED: + REQUIRE( v.capacity() >= V ) +with expansion: + 6 >= 6 + +------------------------------------------------------------------------------- +TemplateTestSig: vectors can be sized and resized - (std::tuple), 6 + reserving bigger changes capacity but not size +------------------------------------------------------------------------------- +Misc.tests.cpp: +............................................................................... + +Misc.tests.cpp:: PASSED: + REQUIRE( v.size() == V ) +with expansion: + 6 == 6 + +Misc.tests.cpp:: PASSED: + REQUIRE( v.capacity() >= 2 * V ) +with expansion: + 12 >= 12 + +------------------------------------------------------------------------------- +TemplateTestSig: vectors can be sized and resized - (std::tuple), 6 +------------------------------------------------------------------------------- +Misc.tests.cpp: +............................................................................... + +Misc.tests.cpp:: PASSED: + REQUIRE( v.size() == V ) +with expansion: + 6 == 6 + +Misc.tests.cpp:: PASSED: + REQUIRE( v.capacity() >= V ) +with expansion: + 6 >= 6 + +------------------------------------------------------------------------------- +TemplateTestSig: vectors can be sized and resized - (std::tuple), 6 + reserving smaller does not change size or capacity +------------------------------------------------------------------------------- +Misc.tests.cpp: +............................................................................... + +Misc.tests.cpp:: PASSED: + REQUIRE( v.size() == V ) +with expansion: + 6 == 6 + +Misc.tests.cpp:: PASSED: + REQUIRE( v.capacity() >= V ) +with expansion: + 6 >= 6 + +------------------------------------------------------------------------------- +TemplateTestSig: vectors can be sized and resized - float,4 +------------------------------------------------------------------------------- +Misc.tests.cpp: +............................................................................... + +Misc.tests.cpp:: PASSED: + REQUIRE( v.size() == V ) +with expansion: + 4 == 4 + +Misc.tests.cpp:: PASSED: + REQUIRE( v.capacity() >= V ) +with expansion: + 4 >= 4 + +------------------------------------------------------------------------------- +TemplateTestSig: vectors can be sized and resized - float,4 + resizing bigger changes size and capacity +------------------------------------------------------------------------------- +Misc.tests.cpp: +............................................................................... + +Misc.tests.cpp:: PASSED: + REQUIRE( v.size() == 2 * V ) +with expansion: + 8 == 8 + +Misc.tests.cpp:: PASSED: + REQUIRE( v.capacity() >= 2 * V ) +with expansion: + 8 >= 8 + +------------------------------------------------------------------------------- +TemplateTestSig: vectors can be sized and resized - float,4 +------------------------------------------------------------------------------- +Misc.tests.cpp: +............................................................................... + +Misc.tests.cpp:: PASSED: + REQUIRE( v.size() == V ) +with expansion: + 4 == 4 + +Misc.tests.cpp:: PASSED: + REQUIRE( v.capacity() >= V ) +with expansion: + 4 >= 4 + +------------------------------------------------------------------------------- +TemplateTestSig: vectors can be sized and resized - float,4 + resizing smaller changes size but not capacity +------------------------------------------------------------------------------- +Misc.tests.cpp: +............................................................................... + +Misc.tests.cpp:: PASSED: + REQUIRE( v.size() == 0 ) +with expansion: + 0 == 0 + +Misc.tests.cpp:: PASSED: + REQUIRE( v.capacity() >= V ) +with expansion: + 4 >= 4 + +------------------------------------------------------------------------------- +TemplateTestSig: vectors can be sized and resized - float,4 + resizing smaller changes size but not capacity + We can use the 'swap trick' to reset the capacity +------------------------------------------------------------------------------- +Misc.tests.cpp: +............................................................................... + +Misc.tests.cpp:: PASSED: + REQUIRE( v.capacity() == 0 ) +with expansion: + 0 == 0 + +------------------------------------------------------------------------------- +TemplateTestSig: vectors can be sized and resized - float,4 +------------------------------------------------------------------------------- +Misc.tests.cpp: +............................................................................... + +Misc.tests.cpp:: PASSED: + REQUIRE( v.size() == V ) +with expansion: + 4 == 4 + +Misc.tests.cpp:: PASSED: + REQUIRE( v.capacity() >= V ) +with expansion: + 4 >= 4 + +------------------------------------------------------------------------------- +TemplateTestSig: vectors can be sized and resized - float,4 + reserving bigger changes capacity but not size +------------------------------------------------------------------------------- +Misc.tests.cpp: +............................................................................... + +Misc.tests.cpp:: PASSED: + REQUIRE( v.size() == V ) +with expansion: + 4 == 4 + +Misc.tests.cpp:: PASSED: + REQUIRE( v.capacity() >= 2 * V ) +with expansion: + 8 >= 8 + +------------------------------------------------------------------------------- +TemplateTestSig: vectors can be sized and resized - float,4 +------------------------------------------------------------------------------- +Misc.tests.cpp: +............................................................................... + +Misc.tests.cpp:: PASSED: + REQUIRE( v.size() == V ) +with expansion: + 4 == 4 + +Misc.tests.cpp:: PASSED: + REQUIRE( v.capacity() >= V ) +with expansion: + 4 >= 4 + +------------------------------------------------------------------------------- +TemplateTestSig: vectors can be sized and resized - float,4 + reserving smaller does not change size or capacity +------------------------------------------------------------------------------- +Misc.tests.cpp: +............................................................................... + +Misc.tests.cpp:: PASSED: + REQUIRE( v.size() == V ) +with expansion: + 4 == 4 + +Misc.tests.cpp:: PASSED: + REQUIRE( v.capacity() >= V ) +with expansion: + 4 >= 4 + +------------------------------------------------------------------------------- +TemplateTestSig: vectors can be sized and resized - int,5 +------------------------------------------------------------------------------- +Misc.tests.cpp: +............................................................................... + +Misc.tests.cpp:: PASSED: + REQUIRE( v.size() == V ) +with expansion: + 5 == 5 + +Misc.tests.cpp:: PASSED: + REQUIRE( v.capacity() >= V ) +with expansion: + 5 >= 5 + +------------------------------------------------------------------------------- +TemplateTestSig: vectors can be sized and resized - int,5 + resizing bigger changes size and capacity +------------------------------------------------------------------------------- +Misc.tests.cpp: +............................................................................... + +Misc.tests.cpp:: PASSED: + REQUIRE( v.size() == 2 * V ) +with expansion: + 10 == 10 + +Misc.tests.cpp:: PASSED: + REQUIRE( v.capacity() >= 2 * V ) +with expansion: + 10 >= 10 + +------------------------------------------------------------------------------- +TemplateTestSig: vectors can be sized and resized - int,5 +------------------------------------------------------------------------------- +Misc.tests.cpp: +............................................................................... + +Misc.tests.cpp:: PASSED: + REQUIRE( v.size() == V ) +with expansion: + 5 == 5 + +Misc.tests.cpp:: PASSED: + REQUIRE( v.capacity() >= V ) +with expansion: + 5 >= 5 + +------------------------------------------------------------------------------- +TemplateTestSig: vectors can be sized and resized - int,5 + resizing smaller changes size but not capacity +------------------------------------------------------------------------------- +Misc.tests.cpp: +............................................................................... + +Misc.tests.cpp:: PASSED: + REQUIRE( v.size() == 0 ) +with expansion: + 0 == 0 + +Misc.tests.cpp:: PASSED: + REQUIRE( v.capacity() >= V ) +with expansion: + 5 >= 5 + +------------------------------------------------------------------------------- +TemplateTestSig: vectors can be sized and resized - int,5 + resizing smaller changes size but not capacity + We can use the 'swap trick' to reset the capacity +------------------------------------------------------------------------------- +Misc.tests.cpp: +............................................................................... + +Misc.tests.cpp:: PASSED: + REQUIRE( v.capacity() == 0 ) +with expansion: + 0 == 0 + +------------------------------------------------------------------------------- +TemplateTestSig: vectors can be sized and resized - int,5 +------------------------------------------------------------------------------- +Misc.tests.cpp: +............................................................................... + +Misc.tests.cpp:: PASSED: + REQUIRE( v.size() == V ) +with expansion: + 5 == 5 + +Misc.tests.cpp:: PASSED: + REQUIRE( v.capacity() >= V ) +with expansion: + 5 >= 5 + +------------------------------------------------------------------------------- +TemplateTestSig: vectors can be sized and resized - int,5 + reserving bigger changes capacity but not size +------------------------------------------------------------------------------- +Misc.tests.cpp: +............................................................................... + +Misc.tests.cpp:: PASSED: + REQUIRE( v.size() == V ) +with expansion: + 5 == 5 + +Misc.tests.cpp:: PASSED: + REQUIRE( v.capacity() >= 2 * V ) +with expansion: + 10 >= 10 + +------------------------------------------------------------------------------- +TemplateTestSig: vectors can be sized and resized - int,5 +------------------------------------------------------------------------------- +Misc.tests.cpp: +............................................................................... + +Misc.tests.cpp:: PASSED: + REQUIRE( v.size() == V ) +with expansion: + 5 == 5 + +Misc.tests.cpp:: PASSED: + REQUIRE( v.capacity() >= V ) +with expansion: + 5 >= 5 + +------------------------------------------------------------------------------- +TemplateTestSig: vectors can be sized and resized - int,5 + reserving smaller does not change size or capacity +------------------------------------------------------------------------------- +Misc.tests.cpp: +............................................................................... + +Misc.tests.cpp:: PASSED: + REQUIRE( v.size() == V ) +with expansion: + 5 == 5 + +Misc.tests.cpp:: PASSED: + REQUIRE( v.capacity() >= V ) +with expansion: + 5 >= 5 + +------------------------------------------------------------------------------- +TemplateTestSig: vectors can be sized and resized - std::string,15 +------------------------------------------------------------------------------- +Misc.tests.cpp: +............................................................................... + +Misc.tests.cpp:: PASSED: + REQUIRE( v.size() == V ) +with expansion: + 15 == 15 + +Misc.tests.cpp:: PASSED: + REQUIRE( v.capacity() >= V ) +with expansion: + 15 >= 15 + +------------------------------------------------------------------------------- +TemplateTestSig: vectors can be sized and resized - std::string,15 + resizing bigger changes size and capacity +------------------------------------------------------------------------------- +Misc.tests.cpp: +............................................................................... + +Misc.tests.cpp:: PASSED: + REQUIRE( v.size() == 2 * V ) +with expansion: + 30 == 30 + +Misc.tests.cpp:: PASSED: + REQUIRE( v.capacity() >= 2 * V ) +with expansion: + 30 >= 30 + +------------------------------------------------------------------------------- +TemplateTestSig: vectors can be sized and resized - std::string,15 +------------------------------------------------------------------------------- +Misc.tests.cpp: +............................................................................... + +Misc.tests.cpp:: PASSED: + REQUIRE( v.size() == V ) +with expansion: + 15 == 15 + +Misc.tests.cpp:: PASSED: + REQUIRE( v.capacity() >= V ) +with expansion: + 15 >= 15 + +------------------------------------------------------------------------------- +TemplateTestSig: vectors can be sized and resized - std::string,15 + resizing smaller changes size but not capacity +------------------------------------------------------------------------------- +Misc.tests.cpp: +............................................................................... + +Misc.tests.cpp:: PASSED: + REQUIRE( v.size() == 0 ) +with expansion: + 0 == 0 + +Misc.tests.cpp:: PASSED: + REQUIRE( v.capacity() >= V ) +with expansion: + 15 >= 15 + +------------------------------------------------------------------------------- +TemplateTestSig: vectors can be sized and resized - std::string,15 + resizing smaller changes size but not capacity + We can use the 'swap trick' to reset the capacity +------------------------------------------------------------------------------- +Misc.tests.cpp: +............................................................................... + +Misc.tests.cpp:: PASSED: + REQUIRE( v.capacity() == 0 ) +with expansion: + 0 == 0 + +------------------------------------------------------------------------------- +TemplateTestSig: vectors can be sized and resized - std::string,15 +------------------------------------------------------------------------------- +Misc.tests.cpp: +............................................................................... + +Misc.tests.cpp:: PASSED: + REQUIRE( v.size() == V ) +with expansion: + 15 == 15 + +Misc.tests.cpp:: PASSED: + REQUIRE( v.capacity() >= V ) +with expansion: + 15 >= 15 + +------------------------------------------------------------------------------- +TemplateTestSig: vectors can be sized and resized - std::string,15 + reserving bigger changes capacity but not size +------------------------------------------------------------------------------- +Misc.tests.cpp: +............................................................................... + +Misc.tests.cpp:: PASSED: + REQUIRE( v.size() == V ) +with expansion: + 15 == 15 + +Misc.tests.cpp:: PASSED: + REQUIRE( v.capacity() >= 2 * V ) +with expansion: + 30 >= 30 + +------------------------------------------------------------------------------- +TemplateTestSig: vectors can be sized and resized - std::string,15 +------------------------------------------------------------------------------- +Misc.tests.cpp: +............................................................................... + +Misc.tests.cpp:: PASSED: + REQUIRE( v.size() == V ) +with expansion: + 15 == 15 + +Misc.tests.cpp:: PASSED: + REQUIRE( v.capacity() >= V ) +with expansion: + 15 >= 15 + +------------------------------------------------------------------------------- +TemplateTestSig: vectors can be sized and resized - std::string,15 + reserving smaller does not change size or capacity +------------------------------------------------------------------------------- +Misc.tests.cpp: +............................................................................... + +Misc.tests.cpp:: PASSED: + REQUIRE( v.size() == V ) +with expansion: + 15 == 15 + +Misc.tests.cpp:: PASSED: + REQUIRE( v.capacity() >= V ) +with expansion: + 15 >= 15 + ------------------------------------------------------------------------------- Test case with one argument ------------------------------------------------------------------------------- @@ -11432,6 +12218,6 @@ Misc.tests.cpp: Misc.tests.cpp:: PASSED: =============================================================================== -test cases: 267 | 184 passed | 79 failed | 4 failed as expected -assertions: 1470 | 1308 passed | 141 failed | 21 failed as expected +test cases: 289 | 199 passed | 86 failed | 4 failed as expected +assertions: 1556 | 1387 passed | 148 failed | 21 failed as expected diff --git a/projects/SelfTest/Baselines/junit.sw.approved.txt b/projects/SelfTest/Baselines/junit.sw.approved.txt index f4d8b37db5..94f0138552 100644 --- a/projects/SelfTest/Baselines/junit.sw.approved.txt +++ b/projects/SelfTest/Baselines/junit.sw.approved.txt @@ -1,7 +1,7 @@ - + @@ -119,6 +119,30 @@ Class.tests.cpp: + + +Class.tests.cpp: + + + + +Class.tests.cpp: + + + + +Class.tests.cpp: + + + + +Class.tests.cpp: + + + + + + Class.tests.cpp: @@ -137,6 +161,24 @@ Class.tests.cpp: + + +Class.tests.cpp: + + + + +Class.tests.cpp: + + + + +Class.tests.cpp: + + + + + Class.tests.cpp: @@ -147,6 +189,10 @@ Class.tests.cpp: + + + + @@ -720,6 +766,30 @@ Misc.tests.cpp: + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/projects/SelfTest/Baselines/xml.sw.approved.txt b/projects/SelfTest/Baselines/xml.sw.approved.txt index 7fcb4f5c35..dd2c3f4a96 100644 --- a/projects/SelfTest/Baselines/xml.sw.approved.txt +++ b/projects/SelfTest/Baselines/xml.sw.approved.txt @@ -1318,6 +1318,94 @@ Nor would this + + + + Template_Fixture_2<TestType>{}.m_a.size() < 2 + + + 6 < 2 + + + + + + + + Template_Fixture_2<TestType>{}.m_a.size() < 2 + + + 2 < 2 + + + + + + + + Template_Fixture_2<TestType>{}.m_a.size() < 2 + + + 6 < 2 + + + + + + + + Template_Fixture_2<TestType>{}.m_a.size() < 2 + + + 2 < 2 + + + + + + + + Template_Fixture_2<TestType>{}.m_a.size() >= 2 + + + 6 >= 2 + + + + + + + + Template_Fixture_2<TestType>{}.m_a.size() >= 2 + + + 2 >= 2 + + + + + + + + Template_Fixture_2<TestType>{}.m_a.size() >= 2 + + + 6 >= 2 + + + + + + + + Template_Fixture_2<TestType>{}.m_a.size() >= 2 + + + 2 >= 2 + + + + @@ -1384,6 +1472,72 @@ Nor would this + + + + Nttp_Fixture<V>::value == 0 + + + 1 == 0 + + + + + + + + Nttp_Fixture<V>::value == 0 + + + 3 == 0 + + + + + + + + Nttp_Fixture<V>::value == 0 + + + 6 == 0 + + + + + + + + Nttp_Fixture<V>::value > 0 + + + 1 > 0 + + + + + + + + Nttp_Fixture<V>::value > 0 + + + 3 > 0 + + + + + + + + Nttp_Fixture<V>::value > 0 + + + 6 > 0 + + + + @@ -1450,6 +1604,50 @@ Nor would this + + + + x.size() > 0 + + + 42 > 0 + + + + + + + + x.size() > 0 + + + 9 > 0 + + + + + + + + x.size() > 0 + + + 42 > 0 + + + + + + + + x.size() > 0 + + + 9 > 0 + + + + @@ -10198,6 +10396,622 @@ Message from section two + + + + v.size() == V + + + 6 == 6 + + + + + v.capacity() >= V + + + 6 >= 6 + + +
+ + + v.size() == 2 * V + + + 12 == 12 + + + + + v.capacity() >= 2 * V + + + 12 >= 12 + + + +
+ + + v.size() == V + + + 6 == 6 + + + + + v.capacity() >= V + + + 6 >= 6 + + +
+ + + v.size() == 0 + + + 0 == 0 + + + + + v.capacity() >= V + + + 6 >= 6 + + +
+ + + v.capacity() == 0 + + + 0 == 0 + + + +
+ +
+ + + v.size() == V + + + 6 == 6 + + + + + v.capacity() >= V + + + 6 >= 6 + + +
+ + + v.size() == V + + + 6 == 6 + + + + + v.capacity() >= 2 * V + + + 12 >= 12 + + + +
+ + + v.size() == V + + + 6 == 6 + + + + + v.capacity() >= V + + + 6 >= 6 + + +
+ + + v.size() == V + + + 6 == 6 + + + + + v.capacity() >= V + + + 6 >= 6 + + + +
+ +
+ + + + v.size() == V + + + 4 == 4 + + + + + v.capacity() >= V + + + 4 >= 4 + + +
+ + + v.size() == 2 * V + + + 8 == 8 + + + + + v.capacity() >= 2 * V + + + 8 >= 8 + + + +
+ + + v.size() == V + + + 4 == 4 + + + + + v.capacity() >= V + + + 4 >= 4 + + +
+ + + v.size() == 0 + + + 0 == 0 + + + + + v.capacity() >= V + + + 4 >= 4 + + +
+ + + v.capacity() == 0 + + + 0 == 0 + + + +
+ +
+ + + v.size() == V + + + 4 == 4 + + + + + v.capacity() >= V + + + 4 >= 4 + + +
+ + + v.size() == V + + + 4 == 4 + + + + + v.capacity() >= 2 * V + + + 8 >= 8 + + + +
+ + + v.size() == V + + + 4 == 4 + + + + + v.capacity() >= V + + + 4 >= 4 + + +
+ + + v.size() == V + + + 4 == 4 + + + + + v.capacity() >= V + + + 4 >= 4 + + + +
+ +
+ + + + v.size() == V + + + 5 == 5 + + + + + v.capacity() >= V + + + 5 >= 5 + + +
+ + + v.size() == 2 * V + + + 10 == 10 + + + + + v.capacity() >= 2 * V + + + 10 >= 10 + + + +
+ + + v.size() == V + + + 5 == 5 + + + + + v.capacity() >= V + + + 5 >= 5 + + +
+ + + v.size() == 0 + + + 0 == 0 + + + + + v.capacity() >= V + + + 5 >= 5 + + +
+ + + v.capacity() == 0 + + + 0 == 0 + + + +
+ +
+ + + v.size() == V + + + 5 == 5 + + + + + v.capacity() >= V + + + 5 >= 5 + + +
+ + + v.size() == V + + + 5 == 5 + + + + + v.capacity() >= 2 * V + + + 10 >= 10 + + + +
+ + + v.size() == V + + + 5 == 5 + + + + + v.capacity() >= V + + + 5 >= 5 + + +
+ + + v.size() == V + + + 5 == 5 + + + + + v.capacity() >= V + + + 5 >= 5 + + + +
+ +
+ + + + v.size() == V + + + 15 == 15 + + + + + v.capacity() >= V + + + 15 >= 15 + + +
+ + + v.size() == 2 * V + + + 30 == 30 + + + + + v.capacity() >= 2 * V + + + 30 >= 30 + + + +
+ + + v.size() == V + + + 15 == 15 + + + + + v.capacity() >= V + + + 15 >= 15 + + +
+ + + v.size() == 0 + + + 0 == 0 + + + + + v.capacity() >= V + + + 15 >= 15 + + +
+ + + v.capacity() == 0 + + + 0 == 0 + + + +
+ +
+ + + v.size() == V + + + 15 == 15 + + + + + v.capacity() >= V + + + 15 >= 15 + + +
+ + + v.size() == V + + + 15 == 15 + + + + + v.capacity() >= 2 * V + + + 30 >= 30 + + + +
+ + + v.size() == V + + + 15 == 15 + + + + + v.capacity() >= V + + + 15 >= 15 + + +
+ + + v.size() == V + + + 15 == 15 + + + + + v.capacity() >= V + + + 15 >= 15 + + + +
+ +
@@ -13772,7 +14586,7 @@ loose text artifact
- + - +