From 9312dc8b397e566a5258958b76ac9bd0ba22982d Mon Sep 17 00:00:00 2001 From: "HuYingzhuo(hugo/hyzboy)" Date: Mon, 18 Sep 2023 22:27:56 +0800 Subject: [PATCH] added ActiveDataManagerTest.cpp --- CMakeLists.txt | 4 +- datatype/ActiveDataManagerTest.cpp | 121 +++++++++++++++++++++++++++++ datatype/ActiveIDManagerTest.cpp | 2 +- datatype/UserInfo.h | 2 +- 4 files changed, 125 insertions(+), 4 deletions(-) create mode 100644 datatype/ActiveDataManagerTest.cpp diff --git a/CMakeLists.txt b/CMakeLists.txt index ffc2774..d785feb 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -68,10 +68,10 @@ add_executable(PoolTest datatype/PoolTest.cpp) set_example_project_folder("DataType/DataArray" PoolTest) add_executable(ActiveIDManagerTest datatype/ActiveIDManagerTest.cpp) -set_example_project_folder("DataType/DataArray" ActiveIDManagerTest) +cm_example_project("DataType/DataArray" ActiveIDManagerTest) add_executable(ActiveDataManagerTest datatype/ActiveDataManagerTest.cpp) -set_example_project_folder("DataType/DataArray" ActiveDataManagerTest) +cm_example_project("DataType/DataArray" ActiveDataManagerTest) add_executable(MapTest datatype/MapTest.cpp) set_example_project_folder("DataType/DataArray" MapTest) diff --git a/datatype/ActiveDataManagerTest.cpp b/datatype/ActiveDataManagerTest.cpp new file mode 100644 index 0000000..518d7d4 --- /dev/null +++ b/datatype/ActiveDataManagerTest.cpp @@ -0,0 +1,121 @@ +#include +#include +#include +#include"UserInfo.h" + +using namespace hgl; +using namespace std; + +void DebugOutputArray(const char *hint,const int **id,const int count) +{ + cout<<"("< &da) +{ + DebugOutputArray(hint,ambm,da.GetData(),da.GetCount()); +} + +void DebugAIMOutput(const char *hint,const ActiveMemoryBlockManager &ambm) +{ + cout<