mirror of
https://github.com/catchorg/Catch2.git
synced 2025-11-16 10:59:31 +01:00
Fix non-default-constructible type lists used in TEMPLATE_LIST_TEST_CASE (#1697)
* Fix non-default-constructible type lists used in TEMPLATE_LIST_TEST_CASE std::tuple is not default constructible when the first type is not default-constuctible. Therefore it can not be instantiated. to circumvent this, we have to use std::declval in the unevaluate decltype context.
This commit is contained in:
committed by
Martin Hořeňovský
parent
a22b7df46c
commit
e7c26f09d1
@@ -9895,6 +9895,39 @@ Message from section two
|
||||
</Expression>
|
||||
<OverallResult success="true"/>
|
||||
</TestCase>
|
||||
<TestCase name="Template test case with test types specified inside non-default-constructible std::tuple - MyNonDefaultConstructibleTypes - 0" tags="[list][template]" filename="projects/<exe-name>/UsageTests/Misc.tests.cpp" >
|
||||
<Expression success="true" type="REQUIRE" filename="projects/<exe-name>/UsageTests/Misc.tests.cpp" >
|
||||
<Original>
|
||||
sizeof(TestType) > 0
|
||||
</Original>
|
||||
<Expanded>
|
||||
1 > 0
|
||||
</Expanded>
|
||||
</Expression>
|
||||
<OverallResult success="true"/>
|
||||
</TestCase>
|
||||
<TestCase name="Template test case with test types specified inside non-default-constructible std::tuple - MyNonDefaultConstructibleTypes - 1" tags="[list][template]" filename="projects/<exe-name>/UsageTests/Misc.tests.cpp" >
|
||||
<Expression success="true" type="REQUIRE" filename="projects/<exe-name>/UsageTests/Misc.tests.cpp" >
|
||||
<Original>
|
||||
sizeof(TestType) > 0
|
||||
</Original>
|
||||
<Expanded>
|
||||
1 > 0
|
||||
</Expanded>
|
||||
</Expression>
|
||||
<OverallResult success="true"/>
|
||||
</TestCase>
|
||||
<TestCase name="Template test case with test types specified inside non-default-constructible std::tuple - MyNonDefaultConstructibleTypes - 2" tags="[list][template]" filename="projects/<exe-name>/UsageTests/Misc.tests.cpp" >
|
||||
<Expression success="true" type="REQUIRE" filename="projects/<exe-name>/UsageTests/Misc.tests.cpp" >
|
||||
<Original>
|
||||
sizeof(TestType) > 0
|
||||
</Original>
|
||||
<Expanded>
|
||||
4 > 0
|
||||
</Expanded>
|
||||
</Expression>
|
||||
<OverallResult success="true"/>
|
||||
</TestCase>
|
||||
<TestCase name="Template test case with test types specified inside std::tuple - MyTypes - 0" tags="[list][template]" filename="projects/<exe-name>/UsageTests/Misc.tests.cpp" >
|
||||
<Expression success="true" type="REQUIRE" filename="projects/<exe-name>/UsageTests/Misc.tests.cpp" >
|
||||
<Original>
|
||||
@@ -14734,7 +14767,7 @@ loose text artifact
|
||||
</Section>
|
||||
<OverallResult success="true"/>
|
||||
</TestCase>
|
||||
<OverallResults successes="1398" failures="149" expectedFailures="21"/>
|
||||
<OverallResults successes="1401" failures="149" expectedFailures="21"/>
|
||||
</Group>
|
||||
<OverallResults successes="1398" failures="148" expectedFailures="21"/>
|
||||
<OverallResults successes="1401" failures="148" expectedFailures="21"/>
|
||||
</Catch>
|
||||
|
||||
Reference in New Issue
Block a user