Browse Source

test: use shared empty type

Michele Caini 2 years ago
parent
commit
a4f2ba1ab8
1 changed files with 2 additions and 3 deletions
  1. 2 3
      test/entt/entity/component.cpp

+ 2 - 3
test/entt/entity/component.cpp

@@ -2,10 +2,9 @@
 #include <entt/config/config.h>
 #include <entt/entity/component.hpp>
 #include "../common/boxed_int.h"
+#include "../common/empty.h"
 #include "../common/non_movable.h"
 
-struct empty {};
-
 struct self_contained {
     static constexpr auto in_place_delete = true;
     static constexpr auto page_size = 4u;
@@ -28,7 +27,7 @@ TEST(Component, VoidType) {
 }
 
 TEST(Component, Empty) {
-    using traits_type = entt::component_traits<empty>;
+    using traits_type = entt::component_traits<test::empty>;
 
     ASSERT_FALSE(traits_type::in_place_delete);
     ASSERT_EQ(traits_type::page_size, 0u);