diff --git a/test/entt/core/any.cpp b/test/entt/core/any.cpp index e3d50a26c..5dffbf0c0 100644 --- a/test/entt/core/any.cpp +++ b/test/entt/core/any.cpp @@ -85,7 +85,6 @@ TEST_F(Any, Empty) { entt::any any{}; ASSERT_FALSE(any); - ASSERT_TRUE(any.owner()); // NOLINT ASSERT_EQ(any.policy(), entt::any_policy::owner); ASSERT_EQ(any.type(), entt::type_id()); ASSERT_EQ(entt::any_cast(&any), nullptr); @@ -96,7 +95,6 @@ TEST_F(Any, SBOInPlaceTypeConstruction) { entt::any any{std::in_place_type, 2}; ASSERT_TRUE(any); - ASSERT_TRUE(any.owner()); // NOLINT ASSERT_EQ(any.policy(), entt::any_policy::owner); ASSERT_EQ(any.type(), entt::type_id()); ASSERT_EQ(entt::any_cast(&any), nullptr); @@ -105,7 +103,6 @@ TEST_F(Any, SBOInPlaceTypeConstruction) { auto other = any.as_ref(); ASSERT_TRUE(other); - ASSERT_FALSE(other.owner()); // NOLINT ASSERT_EQ(other.policy(), entt::any_policy::ref); ASSERT_EQ(other.type(), entt::type_id()); ASSERT_EQ(entt::any_cast(other), 2); @@ -117,7 +114,6 @@ TEST_F(Any, SBOAsRefConstruction) { entt::any any{entt::forward_as_any(value)}; ASSERT_TRUE(any); - ASSERT_FALSE(any.owner()); // NOLINT ASSERT_EQ(any.policy(), entt::any_policy::ref); ASSERT_EQ(any.type(), entt::type_id()); @@ -136,7 +132,6 @@ TEST_F(Any, SBOAsRefConstruction) { any.emplace(value); ASSERT_TRUE(any); - ASSERT_FALSE(any.owner()); // NOLINT ASSERT_EQ(any.policy(), entt::any_policy::ref); ASSERT_EQ(any.type(), entt::type_id()); ASSERT_EQ(entt::any_cast(&any), &value); @@ -144,7 +139,6 @@ TEST_F(Any, SBOAsRefConstruction) { auto other = any.as_ref(); ASSERT_TRUE(other); - ASSERT_FALSE(other.owner()); // NOLINT ASSERT_EQ(other.policy(), entt::any_policy::ref); ASSERT_EQ(other.type(), entt::type_id()); ASSERT_EQ(entt::any_cast(other), 2); @@ -156,7 +150,6 @@ TEST_F(Any, SBOAsConstRefConstruction) { entt::any any{entt::forward_as_any(value)}; ASSERT_TRUE(any); - ASSERT_FALSE(any.owner()); // NOLINT ASSERT_EQ(any.policy(), entt::any_policy::cref); ASSERT_EQ(any.type(), entt::type_id()); @@ -175,7 +168,6 @@ TEST_F(Any, SBOAsConstRefConstruction) { any.emplace(value); ASSERT_TRUE(any); - ASSERT_FALSE(any.owner()); // NOLINT ASSERT_EQ(any.policy(), entt::any_policy::cref); ASSERT_EQ(any.type(), entt::type_id()); ASSERT_EQ(entt::any_cast(&any), &value); @@ -183,7 +175,6 @@ TEST_F(Any, SBOAsConstRefConstruction) { auto other = any.as_ref(); ASSERT_TRUE(other); - ASSERT_FALSE(other.owner()); // NOLINT ASSERT_EQ(other.policy(), entt::any_policy::cref); ASSERT_EQ(other.type(), entt::type_id()); ASSERT_EQ(entt::any_cast(other), 2); diff --git a/test/entt/core/iterator.cpp b/test/entt/core/iterator.cpp index 1abda51f5..22d06ffda 100644 --- a/test/entt/core/iterator.cpp +++ b/test/entt/core/iterator.cpp @@ -10,9 +10,9 @@ TEST(InputIteratorPointer, Functionalities) { ASSERT_EQ(ptr->value, 0); - ptr->value = 42; // NOLINT + ptr->value = 2; - ASSERT_EQ(ptr->value, 42); + ASSERT_EQ(ptr->value, 2); ASSERT_EQ(ptr->value, (*ptr).value); ASSERT_EQ(ptr.operator->(), &ptr.operator*()); } @@ -46,7 +46,7 @@ TEST(IterableAdaptor, Functionalities) { ASSERT_EQ(*++iterable.cbegin(), 2); ASSERT_EQ(++iterable.cbegin(), --iterable.end()); - for(auto value: entt::iterable_adaptor{vec.data(), vec.data() + 1u}) { // NOLINT + for(auto value: entt::iterable_adaptor{&vec[0u], &vec[1u]}) { ASSERT_EQ(value, 1); } } diff --git a/test/entt/core/memory.cpp b/test/entt/core/memory.cpp index 6fbb0cd2a..c7e7f23ea 100644 --- a/test/entt/core/memory.cpp +++ b/test/entt/core/memory.cpp @@ -217,9 +217,9 @@ TEST(UninitializedConstructUsingAllocator, NoUsesAllocatorConstruction) { alignas(int) std::byte storage[sizeof(int)]; // NOLINT const std::allocator allocator{}; - int *value = entt::uninitialized_construct_using_allocator(reinterpret_cast(&storage), allocator, 42); // NOLINT + int *value = entt::uninitialized_construct_using_allocator(reinterpret_cast(&storage), allocator, 1); // NOLINT - ASSERT_EQ(*value, 42); + ASSERT_EQ(*value, 1); } #if defined(ENTT_HAS_TRACKED_MEMORY_RESOURCE) diff --git a/test/entt/core/monostate.cpp b/test/entt/core/monostate.cpp index 6a47b85ef..8414a46e1 100644 --- a/test/entt/core/monostate.cpp +++ b/test/entt/core/monostate.cpp @@ -12,11 +12,11 @@ TEST(Monostate, Functionalities) { ASSERT_EQ(i_pre, int{}); entt::monostate<"foobar"_hs>{} = true; - entt::monostate_v<"foobar"_hs> = 42; // NOLINT + entt::monostate_v<"foobar"_hs> = 2; const bool &b_post = entt::monostate<"foobar"_hs>{}; const int &i_post = entt::monostate_v; ASSERT_TRUE(b_post); - ASSERT_EQ(i_post, 42); + ASSERT_EQ(i_post, 2); } diff --git a/test/entt/core/tuple.cpp b/test/entt/core/tuple.cpp index 25076eee8..774cf59ad 100644 --- a/test/entt/core/tuple.cpp +++ b/test/entt/core/tuple.cpp @@ -11,8 +11,8 @@ TEST(Tuple, IsTuple) { } TEST(Tuple, UnwrapTuple) { - auto single = std::make_tuple(42); // NOLINT - auto multi = std::make_tuple(42, 'c'); // NOLINT + auto single = std::make_tuple(2); + auto multi = std::make_tuple(2, 'c'); auto ref = std::forward_as_tuple(std::get<0>(single)); testing::StaticAssertTypeEq(); @@ -27,9 +27,9 @@ TEST(Tuple, UnwrapTuple) { testing::StaticAssertTypeEq &>(); testing::StaticAssertTypeEq(); - ASSERT_EQ(entt::unwrap_tuple(single), 42); + ASSERT_EQ(entt::unwrap_tuple(single), 2); ASSERT_EQ(entt::unwrap_tuple(multi), multi); - ASSERT_EQ(entt::unwrap_tuple(std::move(ref)), 42); + ASSERT_EQ(entt::unwrap_tuple(std::move(ref)), 2); } TEST(Tuple, ForwardApply) { @@ -40,8 +40,8 @@ TEST(Tuple, ForwardApply) { ASSERT_EQ(first(std::make_tuple()), 0u); ASSERT_EQ(std::as_const(first)(std::make_tuple()), 0u); - ASSERT_EQ(second(std::make_tuple(42)), 42); - ASSERT_EQ(std::as_const(second)(std::make_tuple(42)), 42); + ASSERT_EQ(second(std::make_tuple(2)), 2); + ASSERT_EQ(std::as_const(second)(std::make_tuple(2)), 2); ASSERT_EQ(third(std::make_tuple('a', 1)), 'b'); ASSERT_EQ(std::as_const(third)(std::make_tuple('a', 1)), 'b'); diff --git a/test/entt/core/type_traits.cpp b/test/entt/core/type_traits.cpp index 36fde2e44..e63e4caeb 100644 --- a/test/entt/core/type_traits.cpp +++ b/test/entt/core/type_traits.cpp @@ -31,7 +31,7 @@ struct clazz { }; int free_function(int, const double &) { - return 42; // NOLINT + return 64; } template @@ -70,8 +70,8 @@ TEST_F(UnpackAsType, Functionalities) { } TEST_F(UnpackAsValue, Functionalities) { - ASSERT_EQ((this->test_for<2>()('c', 42., true)), 6); - ASSERT_EQ((this->test_for()('c', 42.)), 2); + ASSERT_EQ((this->test_for<2>()('c', 1., true)), 6); + ASSERT_EQ((this->test_for()('c', 2.)), 2); } TEST(IntegralConstant, Functionalities) { @@ -162,12 +162,12 @@ TEST(ValueList, Functionalities) { testing::StaticAssertTypeEq, entt::value_list<1>>, entt::value_list<0, 2>>(); ASSERT_EQ((std::tuple_size_v>), 0u); - ASSERT_EQ((std::tuple_size_v>), 1u); - ASSERT_EQ((std::tuple_size_v>), 2u); + ASSERT_EQ((std::tuple_size_v>), 1u); + ASSERT_EQ((std::tuple_size_v>), 2u); - testing::StaticAssertTypeEq>>(); // NOLINT - testing::StaticAssertTypeEq>>(); // NOLINT - testing::StaticAssertTypeEq>>(); // NOLINT + testing::StaticAssertTypeEq>>(); + testing::StaticAssertTypeEq>>(); + testing::StaticAssertTypeEq>>(); } TEST(IsApplicable, Functionalities) { @@ -261,7 +261,7 @@ TEST(NthArgument, Functionalities) { testing::StaticAssertTypeEq, float>(); testing::StaticAssertTypeEq, bool>(); - ASSERT_EQ(free_function(entt::nth_argument_t<0u, decltype(&free_function)>{}, entt::nth_argument_t<1u, decltype(&free_function)>{}), 42); + ASSERT_EQ(free_function(entt::nth_argument_t<0u, decltype(&free_function)>{}, entt::nth_argument_t<1u, decltype(&free_function)>{}), 64); } TEST(Tag, Functionalities) { diff --git a/test/entt/core/utility.cpp b/test/entt/core/utility.cpp index ea4a4ea92..1a32175e7 100644 --- a/test/entt/core/utility.cpp +++ b/test/entt/core/utility.cpp @@ -13,7 +13,7 @@ struct functions { TEST(Identity, Functionalities) { const entt::identity identity; - int value = 42; // NOLINT + int value = 2; ASSERT_TRUE(entt::is_transparent_v); ASSERT_EQ(identity(value), value); @@ -44,10 +44,10 @@ TEST(Overloaded, Functionalities) { [&iv](int value) { iv = value; }, [&cv](char value) { cv = value; }}; - func(42); // NOLINT + func(2); func('c'); - ASSERT_EQ(iv, 42); // NOLINT + ASSERT_EQ(iv, 2); ASSERT_EQ(cv, 'c'); }