diff options
author | Mattes D <github@xoft.cz> | 2019-08-26 21:38:34 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-08-26 21:38:34 +0200 |
commit | 74579fbadf0f89154cba5d9157a57f59fcda8f70 (patch) | |
tree | 2aca1ce5d8e41e91adcfe25dfb4bb51369fb865e /tests/SchematicFileSerializer/SchematicFileSerializerTest.cpp | |
parent | Added BlockState implementation for 1.13 support. (diff) | |
download | cuberite-74579fbadf0f89154cba5d9157a57f59fcda8f70.tar cuberite-74579fbadf0f89154cba5d9157a57f59fcda8f70.tar.gz cuberite-74579fbadf0f89154cba5d9157a57f59fcda8f70.tar.bz2 cuberite-74579fbadf0f89154cba5d9157a57f59fcda8f70.tar.lz cuberite-74579fbadf0f89154cba5d9157a57f59fcda8f70.tar.xz cuberite-74579fbadf0f89154cba5d9157a57f59fcda8f70.tar.zst cuberite-74579fbadf0f89154cba5d9157a57f59fcda8f70.zip |
Diffstat (limited to '')
-rw-r--r-- | tests/SchematicFileSerializer/SchematicFileSerializerTest.cpp | 22 |
1 files changed, 5 insertions, 17 deletions
diff --git a/tests/SchematicFileSerializer/SchematicFileSerializerTest.cpp b/tests/SchematicFileSerializer/SchematicFileSerializerTest.cpp index fc18daf93..f4db9852c 100644 --- a/tests/SchematicFileSerializer/SchematicFileSerializerTest.cpp +++ b/tests/SchematicFileSerializer/SchematicFileSerializerTest.cpp @@ -4,6 +4,7 @@ // Implements the SchematicFileSerializer test main entrypoint #include "Globals.h" +#include "../TestHelpers.h" #include "WorldStorage/SchematicFileSerializer.h" @@ -16,28 +17,15 @@ static void DoTest(void) ba.Create(21, 256, 21); ba.RelLine(0, 0, 0, 9, 8, 7, cBlockArea::baTypes | cBlockArea::baMetas, E_BLOCK_WOODEN_STAIRS, 1); AString Schematic; - if (!cSchematicFileSerializer::SaveToSchematicString(ba, Schematic)) - { - assert_test(!"Schematic failed to save!"); - } + TEST_TRUE(cSchematicFileSerializer::SaveToSchematicString(ba, Schematic)); cBlockArea ba2; - if (!cSchematicFileSerializer::LoadFromSchematicString(ba2, Schematic)) - { - assert_test(!"Schematic failed to load!"); - } + TEST_TRUE(cSchematicFileSerializer::LoadFromSchematicString(ba2, Schematic)); } -int main(int argc, char * argv[]) -{ +IMPLEMENT_TEST_MAIN("SchematicFileSerializer", DoTest(); - LOG("SchematicFileSerializer test done."); - return 0; -} - - - - +) |