mirror of
https://github.com/catchorg/Catch2.git
synced 2025-01-15 14:48:00 +00:00
Compare commits
4 Commits
e6da4e10ae
...
65c9a1d31a
Author | SHA1 | Date | |
---|---|---|---|
|
65c9a1d31a | ||
|
fa31d58934 | ||
|
9ac8cad2d1 | ||
|
c71f42cc29 |
@ -71,8 +71,13 @@
|
||||
// REQUIRE(std::string("12") + "34" == "1234")
|
||||
// ```
|
||||
//
|
||||
// Similarly, NVHPC's implementation of `__builtin_constant_p` has a bug which
|
||||
// results in calls to the immediately evaluated lambda expressions to be
|
||||
// reported as unevaluated lambdas.
|
||||
// https://developer.nvidia.com/nvidia_bug/3321845.
|
||||
//
|
||||
// Therefore, `CATCH_INTERNAL_IGNORE_BUT_WARN` is not implemented.
|
||||
# if !defined(__ibmxl__) && !defined(__CUDACC__)
|
||||
# if !defined(__ibmxl__) && !defined(__CUDACC__) && !defined( __NVCOMPILER )
|
||||
# define CATCH_INTERNAL_IGNORE_BUT_WARN(...) (void)__builtin_constant_p(__VA_ARGS__) /* NOLINT(cppcoreguidelines-pro-type-vararg, hicpp-vararg) */
|
||||
# endif
|
||||
|
||||
|
@ -259,3 +259,21 @@ TEST_CASE("Assertion macros support bit operators and bool conversions", "[compi
|
||||
REQUIRE_FALSE(lhs ^ lhs);
|
||||
}
|
||||
|
||||
namespace {
|
||||
struct ImmovableType {
|
||||
ImmovableType() = default;
|
||||
|
||||
ImmovableType(ImmovableType const&) = delete;
|
||||
ImmovableType& operator=(ImmovableType const&) = delete;
|
||||
ImmovableType(ImmovableType&&) = delete;
|
||||
ImmovableType& operator=(ImmovableType&&) = delete;
|
||||
|
||||
friend bool operator==(ImmovableType const&, ImmovableType const&) {
|
||||
return true;
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
TEST_CASE("Immovable types are supported in basic assertions", "[compilation][.approvals]") {
|
||||
REQUIRE(ImmovableType{} == ImmovableType{});
|
||||
}
|
||||
|
@ -245,12 +245,8 @@ namespace { namespace MatchersTests {
|
||||
|
||||
~CustomAllocator() = default;
|
||||
|
||||
using std::allocator<T>::address;
|
||||
using std::allocator<T>::allocate;
|
||||
using std::allocator<T>::construct;
|
||||
using std::allocator<T>::deallocate;
|
||||
using std::allocator<T>::max_size;
|
||||
using std::allocator<T>::destroy;
|
||||
};
|
||||
|
||||
TEST_CASE("Vector matchers", "[matchers][vector]") {
|
||||
|
Loading…
Reference in New Issue
Block a user