Skip to content

Commit

Permalink
Project import generated by Copybara.
Browse files Browse the repository at this point in the history
GitOrigin-RevId: 5c1a647b83ec82b2c387e2d17592d04b2d30b175
  • Loading branch information
Vertexwahn committed Nov 15, 2024
1 parent 7bbd929 commit 403c05c
Show file tree
Hide file tree
Showing 74 changed files with 5,180 additions and 317 deletions.
2 changes: 1 addition & 1 deletion devertexwahn/.bazelversion
Original file line number Diff line number Diff line change
@@ -1 +1 @@
7.4.1rc2
7.4.1
2 changes: 1 addition & 1 deletion devertexwahn/MODULE.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ bazel_dep(name = "rules_cc", version = "0.0.13")
bazel_dep(name = "rules_license", version = "1.0.0")
bazel_dep(name = "rules_pkg", version = "1.0.1")
bazel_dep(name = "rules_python", version = "0.38.0")
bazel_dep(name = "spdlog", version = "1.14.1")
bazel_dep(name = "spdlog", version = "1.15.0")
bazel_dep(name = "xtensor")
bazel_dep(name = "xtl")
bazel_dep(name = "yaml-cpp", version = "0.8.0")
Expand Down
2 changes: 1 addition & 1 deletion third_party/Catch2/docs/tostring.md
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ CATCH_TRANSLATE_EXCEPTION( MyType const& ex ) {
Enums that already have a `<<` overload for `std::ostream` will convert to strings as expected.
If you only need to convert enums to strings for test reporting purposes you can provide a `StringMaker` specialisations as any other type.
However, as a convenience, Catch provides the `REGISTER_ENUM` helper macro that will generate the `StringMaker` specialisation for you with minimal code.
However, as a convenience, Catch provides the `CATCH_REGISTER_ENUM` helper macro that will generate the `StringMaker` specialisation for you with minimal code.
Simply provide it the (qualified) enum name, followed by all the enum values, and you're done!
E.g.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ class IteratorGenerator final : public IGenerator<T> {

template <typename InputIterator,
typename InputSentinel,
typename ResultType = typename std::iterator_traits<InputIterator>::value_type>
typename ResultType = std::remove_const_t<typename std::iterator_traits<InputIterator>::value_type>>
GeneratorWrapper<ResultType> from_range(InputIterator from, InputSentinel to) {
return GeneratorWrapper<ResultType>(Catch::Detail::make_unique<IteratorGenerator<ResultType>>(from, to));
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -136,8 +136,8 @@ Nor would this
:test-result: SKIP Empty generators can SKIP in constructor
:test-result: PASS Empty stream name opens cout stream
:test-result: FAIL EndsWith string matcher
:test-result: PASS Enums can quickly have stringification enabled using REGISTER_ENUM
:test-result: PASS Enums in namespaces can quickly have stringification enabled using REGISTER_ENUM
:test-result: PASS Enums can quickly have stringification enabled using CATCH_REGISTER_ENUM
:test-result: PASS Enums in namespaces can quickly have stringification enabled using CATCH_REGISTER_ENUM
:test-result: PASS Epsilon only applies to Approx's value
:test-result: XFAIL Equality checks that should fail
:test-result: PASS Equality checks that should succeed
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -134,8 +134,8 @@
:test-result: SKIP Empty generators can SKIP in constructor
:test-result: PASS Empty stream name opens cout stream
:test-result: FAIL EndsWith string matcher
:test-result: PASS Enums can quickly have stringification enabled using REGISTER_ENUM
:test-result: PASS Enums in namespaces can quickly have stringification enabled using REGISTER_ENUM
:test-result: PASS Enums can quickly have stringification enabled using CATCH_REGISTER_ENUM
:test-result: PASS Enums in namespaces can quickly have stringification enabled using CATCH_REGISTER_ENUM
:test-result: PASS Epsilon only applies to Approx's value
:test-result: XFAIL Equality checks that should fail
:test-result: PASS Equality checks that should succeed
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4083,7 +4083,7 @@ with expansion:
insensitive)

-------------------------------------------------------------------------------
Enums can quickly have stringification enabled using REGISTER_ENUM
Enums can quickly have stringification enabled using CATCH_REGISTER_ENUM
-------------------------------------------------------------------------------
EnumToString.tests.cpp:<line number>
...............................................................................
Expand Down Expand Up @@ -4117,7 +4117,7 @@ with expansion:

-------------------------------------------------------------------------------
Enums in namespaces can quickly have stringification enabled using
REGISTER_ENUM
CATCH_REGISTER_ENUM
-------------------------------------------------------------------------------
EnumToString.tests.cpp:<line number>
...............................................................................
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4081,7 +4081,7 @@ with expansion:
insensitive)

-------------------------------------------------------------------------------
Enums can quickly have stringification enabled using REGISTER_ENUM
Enums can quickly have stringification enabled using CATCH_REGISTER_ENUM
-------------------------------------------------------------------------------
EnumToString.tests.cpp:<line number>
...............................................................................
Expand Down Expand Up @@ -4115,7 +4115,7 @@ with expansion:

-------------------------------------------------------------------------------
Enums in namespaces can quickly have stringification enabled using
REGISTER_ENUM
CATCH_REGISTER_ENUM
-------------------------------------------------------------------------------
EnumToString.tests.cpp:<line number>
...............................................................................
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -521,8 +521,8 @@ with expansion:
at Matchers.tests.cpp:<line number>
</failure>
</testcase>
<testcase classname="<exe-name>.global" name="Enums can quickly have stringification enabled using REGISTER_ENUM" time="{duration}" status="run"/>
<testcase classname="<exe-name>.global" name="Enums in namespaces can quickly have stringification enabled using REGISTER_ENUM" time="{duration}" status="run"/>
<testcase classname="<exe-name>.global" name="Enums can quickly have stringification enabled using CATCH_REGISTER_ENUM" time="{duration}" status="run"/>
<testcase classname="<exe-name>.global" name="Enums in namespaces can quickly have stringification enabled using CATCH_REGISTER_ENUM" time="{duration}" status="run"/>
<testcase classname="<exe-name>.global" name="Epsilon only applies to Approx's value" time="{duration}" status="run"/>
<testcase classname="<exe-name>.global" name="Equality checks that should fail" time="{duration}" status="run">
<skipped message="TEST_CASE tagged with !mayfail"/>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -520,8 +520,8 @@ with expansion:
at Matchers.tests.cpp:<line number>
</failure>
</testcase>
<testcase classname="<exe-name>.global" name="Enums can quickly have stringification enabled using REGISTER_ENUM" time="{duration}" status="run"/>
<testcase classname="<exe-name>.global" name="Enums in namespaces can quickly have stringification enabled using REGISTER_ENUM" time="{duration}" status="run"/>
<testcase classname="<exe-name>.global" name="Enums can quickly have stringification enabled using CATCH_REGISTER_ENUM" time="{duration}" status="run"/>
<testcase classname="<exe-name>.global" name="Enums in namespaces can quickly have stringification enabled using CATCH_REGISTER_ENUM" time="{duration}" status="run"/>
<testcase classname="<exe-name>.global" name="Epsilon only applies to Approx's value" time="{duration}" status="run"/>
<testcase classname="<exe-name>.global" name="Equality checks that should fail" time="{duration}" status="run">
<skipped message="TEST_CASE tagged with !mayfail"/>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -998,8 +998,8 @@ at Decomposition.tests.cpp:<line number>
</testCase>
</file>
<file path="tests/<exe-name>/UsageTests/EnumToString.tests.cpp">
<testCase name="Enums can quickly have stringification enabled using REGISTER_ENUM" duration="{duration}"/>
<testCase name="Enums in namespaces can quickly have stringification enabled using REGISTER_ENUM" duration="{duration}"/>
<testCase name="Enums can quickly have stringification enabled using CATCH_REGISTER_ENUM" duration="{duration}"/>
<testCase name="Enums in namespaces can quickly have stringification enabled using CATCH_REGISTER_ENUM" duration="{duration}"/>
<testCase name="toString(enum class w/operator&lt;&lt;)" duration="{duration}"/>
<testCase name="toString(enum class)" duration="{duration}"/>
<testCase name="toString(enum w/operator&lt;&lt;)" duration="{duration}"/>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -997,8 +997,8 @@ at Decomposition.tests.cpp:<line number>
</testCase>
</file>
<file path="tests/<exe-name>/UsageTests/EnumToString.tests.cpp">
<testCase name="Enums can quickly have stringification enabled using REGISTER_ENUM" duration="{duration}"/>
<testCase name="Enums in namespaces can quickly have stringification enabled using REGISTER_ENUM" duration="{duration}"/>
<testCase name="Enums can quickly have stringification enabled using CATCH_REGISTER_ENUM" duration="{duration}"/>
<testCase name="Enums in namespaces can quickly have stringification enabled using CATCH_REGISTER_ENUM" duration="{duration}"/>
<testCase name="toString(enum class w/operator&lt;&lt;)" duration="{duration}"/>
<testCase name="toString(enum class)" duration="{duration}"/>
<testCase name="toString(enum w/operator&lt;&lt;)" duration="{duration}"/>
Expand Down
14 changes: 7 additions & 7 deletions third_party/Catch2/tests/SelfTest/Baselines/tap.sw.approved.txt
Original file line number Diff line number Diff line change
Expand Up @@ -1004,19 +1004,19 @@ ok {test-number} - Catch::makeStream( "" )->isConsole() for: true
not ok {test-number} - testStringForMatching(), EndsWith( "Substring" ) for: "this string contains 'abc' as a substring" ends with: "Substring"
# EndsWith string matcher
not ok {test-number} - testStringForMatching(), EndsWith( "this", Catch::CaseSensitive::No ) for: "this string contains 'abc' as a substring" ends with: "this" (case insensitive)
# Enums can quickly have stringification enabled using REGISTER_ENUM
# Enums can quickly have stringification enabled using CATCH_REGISTER_ENUM
ok {test-number} - stringify( EnumClass3::Value1 ) == "Value1" for: "Value1" == "Value1"
# Enums can quickly have stringification enabled using REGISTER_ENUM
# Enums can quickly have stringification enabled using CATCH_REGISTER_ENUM
ok {test-number} - stringify( EnumClass3::Value2 ) == "Value2" for: "Value2" == "Value2"
# Enums can quickly have stringification enabled using REGISTER_ENUM
# Enums can quickly have stringification enabled using CATCH_REGISTER_ENUM
ok {test-number} - stringify( EnumClass3::Value3 ) == "Value3" for: "Value3" == "Value3"
# Enums can quickly have stringification enabled using REGISTER_ENUM
# Enums can quickly have stringification enabled using CATCH_REGISTER_ENUM
ok {test-number} - stringify( EnumClass3::Value4 ) == "{** unexpected enum value **}" for: "{** unexpected enum value **}" == "{** unexpected enum value **}"
# Enums can quickly have stringification enabled using REGISTER_ENUM
# Enums can quickly have stringification enabled using CATCH_REGISTER_ENUM
ok {test-number} - stringify( ec3 ) == "Value2" for: "Value2" == "Value2"
# Enums in namespaces can quickly have stringification enabled using REGISTER_ENUM
# Enums in namespaces can quickly have stringification enabled using CATCH_REGISTER_ENUM
ok {test-number} - stringify( Bikeshed::Colours::Red ) == "Red" for: "Red" == "Red"
# Enums in namespaces can quickly have stringification enabled using REGISTER_ENUM
# Enums in namespaces can quickly have stringification enabled using CATCH_REGISTER_ENUM
ok {test-number} - stringify( Bikeshed::Colours::Blue ) == "Blue" for: "Blue" == "Blue"
# Epsilon only applies to Approx's value
ok {test-number} - 101.01 != Approx(100).epsilon(0.01) for: 101.01000000000000512 != Approx( 100.0 )
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1002,19 +1002,19 @@ ok {test-number} - Catch::makeStream( "" )->isConsole() for: true
not ok {test-number} - testStringForMatching(), EndsWith( "Substring" ) for: "this string contains 'abc' as a substring" ends with: "Substring"
# EndsWith string matcher
not ok {test-number} - testStringForMatching(), EndsWith( "this", Catch::CaseSensitive::No ) for: "this string contains 'abc' as a substring" ends with: "this" (case insensitive)
# Enums can quickly have stringification enabled using REGISTER_ENUM
# Enums can quickly have stringification enabled using CATCH_REGISTER_ENUM
ok {test-number} - stringify( EnumClass3::Value1 ) == "Value1" for: "Value1" == "Value1"
# Enums can quickly have stringification enabled using REGISTER_ENUM
# Enums can quickly have stringification enabled using CATCH_REGISTER_ENUM
ok {test-number} - stringify( EnumClass3::Value2 ) == "Value2" for: "Value2" == "Value2"
# Enums can quickly have stringification enabled using REGISTER_ENUM
# Enums can quickly have stringification enabled using CATCH_REGISTER_ENUM
ok {test-number} - stringify( EnumClass3::Value3 ) == "Value3" for: "Value3" == "Value3"
# Enums can quickly have stringification enabled using REGISTER_ENUM
# Enums can quickly have stringification enabled using CATCH_REGISTER_ENUM
ok {test-number} - stringify( EnumClass3::Value4 ) == "{** unexpected enum value **}" for: "{** unexpected enum value **}" == "{** unexpected enum value **}"
# Enums can quickly have stringification enabled using REGISTER_ENUM
# Enums can quickly have stringification enabled using CATCH_REGISTER_ENUM
ok {test-number} - stringify( ec3 ) == "Value2" for: "Value2" == "Value2"
# Enums in namespaces can quickly have stringification enabled using REGISTER_ENUM
# Enums in namespaces can quickly have stringification enabled using CATCH_REGISTER_ENUM
ok {test-number} - stringify( Bikeshed::Colours::Red ) == "Red" for: "Red" == "Red"
# Enums in namespaces can quickly have stringification enabled using REGISTER_ENUM
# Enums in namespaces can quickly have stringification enabled using CATCH_REGISTER_ENUM
ok {test-number} - stringify( Bikeshed::Colours::Blue ) == "Blue" for: "Blue" == "Blue"
# Epsilon only applies to Approx's value
ok {test-number} - 101.01 != Approx(100).epsilon(0.01) for: 101.01000000000000512 != Approx( 100.0 )
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -315,10 +315,10 @@
##teamcity[testFailed name='EndsWith string matcher' message='Matchers.tests.cpp:<line number>|n...............................................................................|n|nMatchers.tests.cpp:<line number>|nexpression failed|n CHECK_THAT( testStringForMatching(), EndsWith( "Substring" ) )|nwith expansion:|n "this string contains |'abc|' as a substring" ends with: "Substring"|n']
##teamcity[testFailed name='EndsWith string matcher' message='Matchers.tests.cpp:<line number>|nexpression failed|n CHECK_THAT( testStringForMatching(), EndsWith( "this", Catch::CaseSensitive::No ) )|nwith expansion:|n "this string contains |'abc|' as a substring" ends with: "this" (case insensitive)|n']
##teamcity[testFinished name='EndsWith string matcher' duration="{duration}"]
##teamcity[testStarted name='Enums can quickly have stringification enabled using REGISTER_ENUM']
##teamcity[testFinished name='Enums can quickly have stringification enabled using REGISTER_ENUM' duration="{duration}"]
##teamcity[testStarted name='Enums in namespaces can quickly have stringification enabled using REGISTER_ENUM']
##teamcity[testFinished name='Enums in namespaces can quickly have stringification enabled using REGISTER_ENUM' duration="{duration}"]
##teamcity[testStarted name='Enums can quickly have stringification enabled using CATCH_REGISTER_ENUM']
##teamcity[testFinished name='Enums can quickly have stringification enabled using CATCH_REGISTER_ENUM' duration="{duration}"]
##teamcity[testStarted name='Enums in namespaces can quickly have stringification enabled using CATCH_REGISTER_ENUM']
##teamcity[testFinished name='Enums in namespaces can quickly have stringification enabled using CATCH_REGISTER_ENUM' duration="{duration}"]
##teamcity[testStarted name='Epsilon only applies to Approx|'s value']
##teamcity[testFinished name='Epsilon only applies to Approx|'s value' duration="{duration}"]
##teamcity[testStarted name='Equality checks that should fail']
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -315,10 +315,10 @@
##teamcity[testFailed name='EndsWith string matcher' message='Matchers.tests.cpp:<line number>|n...............................................................................|n|nMatchers.tests.cpp:<line number>|nexpression failed|n CHECK_THAT( testStringForMatching(), EndsWith( "Substring" ) )|nwith expansion:|n "this string contains |'abc|' as a substring" ends with: "Substring"|n']
##teamcity[testFailed name='EndsWith string matcher' message='Matchers.tests.cpp:<line number>|nexpression failed|n CHECK_THAT( testStringForMatching(), EndsWith( "this", Catch::CaseSensitive::No ) )|nwith expansion:|n "this string contains |'abc|' as a substring" ends with: "this" (case insensitive)|n']
##teamcity[testFinished name='EndsWith string matcher' duration="{duration}"]
##teamcity[testStarted name='Enums can quickly have stringification enabled using REGISTER_ENUM']
##teamcity[testFinished name='Enums can quickly have stringification enabled using REGISTER_ENUM' duration="{duration}"]
##teamcity[testStarted name='Enums in namespaces can quickly have stringification enabled using REGISTER_ENUM']
##teamcity[testFinished name='Enums in namespaces can quickly have stringification enabled using REGISTER_ENUM' duration="{duration}"]
##teamcity[testStarted name='Enums can quickly have stringification enabled using CATCH_REGISTER_ENUM']
##teamcity[testFinished name='Enums can quickly have stringification enabled using CATCH_REGISTER_ENUM' duration="{duration}"]
##teamcity[testStarted name='Enums in namespaces can quickly have stringification enabled using CATCH_REGISTER_ENUM']
##teamcity[testFinished name='Enums in namespaces can quickly have stringification enabled using CATCH_REGISTER_ENUM' duration="{duration}"]
##teamcity[testStarted name='Epsilon only applies to Approx|'s value']
##teamcity[testFinished name='Epsilon only applies to Approx|'s value' duration="{duration}"]
##teamcity[testStarted name='Equality checks that should fail']
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4493,7 +4493,7 @@ C
</Expression>
<OverallResult success="false" skips="0"/>
</TestCase>
<TestCase name="Enums can quickly have stringification enabled using REGISTER_ENUM" filename="tests/<exe-name>/UsageTests/EnumToString.tests.cpp" >
<TestCase name="Enums can quickly have stringification enabled using CATCH_REGISTER_ENUM" filename="tests/<exe-name>/UsageTests/EnumToString.tests.cpp" >
<Expression success="true" type="REQUIRE" filename="tests/<exe-name>/UsageTests/EnumToString.tests.cpp" >
<Original>
stringify( EnumClass3::Value1 ) == "Value1"
Expand Down Expand Up @@ -4538,7 +4538,7 @@ C
</Expression>
<OverallResult success="true" skips="0"/>
</TestCase>
<TestCase name="Enums in namespaces can quickly have stringification enabled using REGISTER_ENUM" filename="tests/<exe-name>/UsageTests/EnumToString.tests.cpp" >
<TestCase name="Enums in namespaces can quickly have stringification enabled using CATCH_REGISTER_ENUM" filename="tests/<exe-name>/UsageTests/EnumToString.tests.cpp" >
<Expression success="true" type="REQUIRE" filename="tests/<exe-name>/UsageTests/EnumToString.tests.cpp" >
<Original>
stringify( Bikeshed::Colours::Red ) == "Red"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4493,7 +4493,7 @@ C
</Expression>
<OverallResult success="false" skips="0"/>
</TestCase>
<TestCase name="Enums can quickly have stringification enabled using REGISTER_ENUM" filename="tests/<exe-name>/UsageTests/EnumToString.tests.cpp" >
<TestCase name="Enums can quickly have stringification enabled using CATCH_REGISTER_ENUM" filename="tests/<exe-name>/UsageTests/EnumToString.tests.cpp" >
<Expression success="true" type="REQUIRE" filename="tests/<exe-name>/UsageTests/EnumToString.tests.cpp" >
<Original>
stringify( EnumClass3::Value1 ) == "Value1"
Expand Down Expand Up @@ -4538,7 +4538,7 @@ C
</Expression>
<OverallResult success="true" skips="0"/>
</TestCase>
<TestCase name="Enums in namespaces can quickly have stringification enabled using REGISTER_ENUM" filename="tests/<exe-name>/UsageTests/EnumToString.tests.cpp" >
<TestCase name="Enums in namespaces can quickly have stringification enabled using CATCH_REGISTER_ENUM" filename="tests/<exe-name>/UsageTests/EnumToString.tests.cpp" >
<Expression success="true" type="REQUIRE" filename="tests/<exe-name>/UsageTests/EnumToString.tests.cpp" >
<Original>
stringify( Bikeshed::Colours::Red ) == "Red"
Expand Down
Loading

0 comments on commit 403c05c

Please sign in to comment.