diff options
Diffstat (limited to 'tests')
-rw-r--r-- | tests/ByteBuffer/CMakeLists.txt | 1 | ||||
-rw-r--r-- | tests/ByteBuffer/Stubs.cpp | 16 | ||||
-rw-r--r-- | tests/Generating/LuaState_Declaration.inc | 5 | ||||
-rw-r--r-- | tests/Generating/LuaState_Typedefs.inc | 1 | ||||
-rw-r--r-- | tests/Generating/Stubs.cpp | 20 | ||||
-rw-r--r-- | tests/LuaThreadStress/LuaState_Declaration.inc | 5 | ||||
-rw-r--r-- | tests/LuaThreadStress/LuaState_Typedefs.inc | 1 | ||||
-rw-r--r-- | tests/LuaThreadStress/Stubs.cpp | 21 |
8 files changed, 69 insertions, 1 deletions
diff --git a/tests/ByteBuffer/CMakeLists.txt b/tests/ByteBuffer/CMakeLists.txt index 12c2f6e3c..06832848e 100644 --- a/tests/ByteBuffer/CMakeLists.txt +++ b/tests/ByteBuffer/CMakeLists.txt @@ -19,6 +19,7 @@ set (SHARED_HDRS set (SRCS ByteBufferTest.cpp + Stubs.cpp ) source_group("Shared" FILES ${SHARED_SRCS} ${SHARED_HDRS}) diff --git a/tests/ByteBuffer/Stubs.cpp b/tests/ByteBuffer/Stubs.cpp new file mode 100644 index 000000000..c3271ff31 --- /dev/null +++ b/tests/ByteBuffer/Stubs.cpp @@ -0,0 +1,16 @@ + +// Stubs.cpp + +// Implements stubs of various Cuberite methods that are needed for linking but not for runtime +// This is required so that we don't bring in the entire Cuberite via dependencies + +#include "Globals.h" +#include "UUID.h" + + + + +void cUUID::FromRaw(const std::array<Byte, 16> &){} + + + diff --git a/tests/Generating/LuaState_Declaration.inc b/tests/Generating/LuaState_Declaration.inc index 4019b26c6..8b342e1b1 100644 --- a/tests/Generating/LuaState_Declaration.inc +++ b/tests/Generating/LuaState_Declaration.inc @@ -2,3 +2,8 @@ // LuaState_Declaration.inc // Dummy include file needed for LuaState to compile successfully + + +bool GetStackValue(int, cUUID *&); + + diff --git a/tests/Generating/LuaState_Typedefs.inc b/tests/Generating/LuaState_Typedefs.inc index 5eba7c6f8..e79633556 100644 --- a/tests/Generating/LuaState_Typedefs.inc +++ b/tests/Generating/LuaState_Typedefs.inc @@ -14,6 +14,7 @@ class cPluginLua; class cBoundingBox; template <typename T> class cItemCallback; class cEntity; +class cUUID; diff --git a/tests/Generating/Stubs.cpp b/tests/Generating/Stubs.cpp index d363576a5..396fa15da 100644 --- a/tests/Generating/Stubs.cpp +++ b/tests/Generating/Stubs.cpp @@ -6,9 +6,11 @@ #include "Globals.h" #include "BlockInfo.h" +#include "UUID.h" #include "Bindings.h" #include "Bindings/DeprecatedBindings.h" #include "Bindings/LuaJson.h" +#include "Bindings/LuaState.h" #include "Bindings/ManualBindings.h" #include "BlockEntities/BlockEntity.h" #include "Blocks/BlockHandler.h" @@ -332,3 +334,21 @@ cBlockEntity * cBlockEntity::Clone(int a_BlockX, int a_BlockY, int a_BlockZ) + +bool cLuaState::GetStackValue(int, cUUID *&) +{ + return false; +} + + + + + +bool cUUID::FromString(const AString&) +{ + return false; +} + + + + diff --git a/tests/LuaThreadStress/LuaState_Declaration.inc b/tests/LuaThreadStress/LuaState_Declaration.inc index 4019b26c6..8b342e1b1 100644 --- a/tests/LuaThreadStress/LuaState_Declaration.inc +++ b/tests/LuaThreadStress/LuaState_Declaration.inc @@ -2,3 +2,8 @@ // LuaState_Declaration.inc // Dummy include file needed for LuaState to compile successfully + + +bool GetStackValue(int, cUUID *&); + + diff --git a/tests/LuaThreadStress/LuaState_Typedefs.inc b/tests/LuaThreadStress/LuaState_Typedefs.inc index 5eba7c6f8..e79633556 100644 --- a/tests/LuaThreadStress/LuaState_Typedefs.inc +++ b/tests/LuaThreadStress/LuaState_Typedefs.inc @@ -14,6 +14,7 @@ class cPluginLua; class cBoundingBox; template <typename T> class cItemCallback; class cEntity; +class cUUID; diff --git a/tests/LuaThreadStress/Stubs.cpp b/tests/LuaThreadStress/Stubs.cpp index 709c7efe5..98fbf5b74 100644 --- a/tests/LuaThreadStress/Stubs.cpp +++ b/tests/LuaThreadStress/Stubs.cpp @@ -7,13 +7,14 @@ #include "Globals.h" #include "BlockInfo.h" #include "Bindings.h" +#include "DeadlockDetect.h" +#include "UUID.h" #include "Bindings/DeprecatedBindings.h" #include "Bindings/LuaJson.h" #include "Bindings/ManualBindings.h" #include "BlockEntities/BlockEntity.h" #include "Blocks/BlockHandler.h" #include "Generating/ChunkDesc.h" -#include "DeadlockDetect.h" @@ -333,3 +334,21 @@ cBlockEntity * cBlockEntity::Clone(int a_BlockX, int a_BlockY, int a_BlockZ) + +bool cLuaState::GetStackValue(int, cUUID *&) +{ + return false; +} + + + + + +bool cUUID::FromString(const AString &) +{ + return true; +} + + + + |