test: std::strcmp ... 🤦‍♂️

This commit is contained in:
Michele Caini
2021-04-06 16:16:52 +02:00
parent 9f8a36f2c9
commit 453f1c6edc
2 changed files with 3 additions and 3 deletions

View File

@@ -973,11 +973,11 @@ TEST_F(Any, DeducedArrayType) {
ASSERT_TRUE(any);
ASSERT_EQ(any.type(), entt::type_id<const char *>());
ASSERT_EQ((std::strcmp("array of char", entt::any_cast<const char *>(any))), 0);
ASSERT_EQ((strcmp("array of char", entt::any_cast<const char *>(any))), 0);
any = "another array of char";
ASSERT_TRUE(any);
ASSERT_EQ(any.type(), entt::type_id<const char *>());
ASSERT_EQ((std::strcmp("another array of char", entt::any_cast<const char *>(any))), 0);
ASSERT_EQ((strcmp("another array of char", entt::any_cast<const char *>(any))), 0);
}

View File

@@ -67,7 +67,7 @@ TEST_F(MetaProp, DeducedArrayType) {
ASSERT_TRUE(prop);
ASSERT_EQ(prop.key(), "char[]"_hs);
ASSERT_EQ(prop.value().type(), entt::resolve<const char *>());
ASSERT_EQ(std::strcmp(prop.value().cast<const char *>(), "char[]"), 0);
ASSERT_EQ(strcmp(prop.value().cast<const char *>(), "char[]"), 0);
}
TEST_F(MetaProp, ReRegistration) {