mirror of
https://github.com/catchorg/Catch2.git
synced 2024-11-22 13:26:10 +01:00
Add integration test for the children completion check fix
This commit is contained in:
parent
800f1b1d3d
commit
9a6551b22b
@ -378,6 +378,8 @@ set_tests_properties(FilteredSection-2 PROPERTIES FAIL_REGULAR_EXPRESSION "No te
|
||||
add_test(NAME ApprovalTests COMMAND ${PYTHON_EXECUTABLE} ${CATCH_DIR}/scripts/approvalTests.py $<TARGET_FILE:SelfTest>)
|
||||
set_tests_properties(ApprovalTests PROPERTIES FAIL_REGULAR_EXPRESSION "Results differed")
|
||||
|
||||
add_test(NAME RegressionCheck-1670 COMMAND $<TARGET_FILE:SelfTest> "#1670 regression check" -c A -r compact)
|
||||
set_tests_properties(RegressionCheck-1670 PROPERTIES PASS_REGULAR_EXPRESSION "Passed 1 test case with 2 assertions.")
|
||||
|
||||
if (CATCH_USE_VALGRIND)
|
||||
add_test(NAME ValgrindRunTests COMMAND valgrind --leak-check=full --error-exitcode=1 $<TARGET_FILE:SelfTest>)
|
||||
|
@ -189,3 +189,18 @@ TEST_CASE( "#1394 nested", "[.][approvals][tracker]" ) {
|
||||
REQUIRE(1 == 0);
|
||||
}
|
||||
}
|
||||
|
||||
// Selecting a "not last" section inside a test case via -c "section" would
|
||||
// previously only run the first subsection, instead of running all of them.
|
||||
// This allows us to check that `"#1670 regression check" -c A` leads to
|
||||
// 2 successful assertions.
|
||||
TEST_CASE("#1670 regression check", "[.approvals][tracker]") {
|
||||
SECTION("A") {
|
||||
SECTION("1") SUCCEED();
|
||||
SECTION("2") SUCCEED();
|
||||
}
|
||||
SECTION("B") {
|
||||
SECTION("1") SUCCEED();
|
||||
SECTION("2") SUCCEED();
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user