add serialization test

This commit is contained in:
David Markowitz 2023-07-31 18:38:26 -07:00
parent a7eb28279e
commit ba409b6ee2

View File

@ -67,9 +67,8 @@ protected:
void TearDown() override { void TearDown() override {
TearDownDependencies(); TearDownDependencies();
} }
};
TEST_F(MovingPlatformComponentTests, MovingPlatformConstructionTest) { void TestSerialization() {
auto* movingPlatformComponent = baseEntity->GetComponent<MovingPlatformComponent>(); auto* movingPlatformComponent = baseEntity->GetComponent<MovingPlatformComponent>();
ASSERT_NE(movingPlatformComponent, nullptr); ASSERT_NE(movingPlatformComponent, nullptr);
uint32_t flags = 0; uint32_t flags = 0;
@ -268,3 +267,12 @@ TEST_F(MovingPlatformComponentTests, MovingPlatformConstructionTest) {
bitStream.Read(hasPlatformSubComponents2); bitStream.Read(hasPlatformSubComponents2);
ASSERT_FALSE(hasPlatformSubComponents2); ASSERT_FALSE(hasPlatformSubComponents2);
} }
};
TEST_F(MovingPlatformComponentTests, MovingPlatformConstructionTest) {
TestSerialization();
}
TEST_F(MovingPlatformComponentTests, MovingPlatformSerializationTest) {
TestSerialization();
}