From 9a0d8089baa4d9c3a0a36c6135a22c55354b44ef Mon Sep 17 00:00:00 2001 From: Yee <2520865+yixinglu@users.noreply.github.com> Date: Wed, 2 Sep 2020 12:30:15 +0800 Subject: [PATCH] Merge all executor tests (#249) Co-authored-by: dutor <440396+dutor@users.noreply.github.com> --- src/executor/CMakeLists.txt | 3 +- src/executor/logic/test/CMakeLists.txt | 62 ------------------- .../{query => }/test/AggregateTest.cpp | 0 src/executor/{query => }/test/CMakeLists.txt | 6 +- .../{query => }/test/DataCollectTest.cpp | 0 .../{query => }/test/DataJoinTest.cpp | 2 +- src/executor/{query => }/test/DedupTest.cpp | 2 +- src/executor/{query => }/test/FilterTest.cpp | 2 +- .../{query => }/test/GetNeighborsTest.cpp | 0 src/executor/{query => }/test/LimitTest.cpp | 2 +- .../{logic => }/test/LogicExecutorsTest.cpp | 0 src/executor/{query => }/test/ProjectTest.cpp | 2 +- src/executor/{query => }/test/QueryTestBase.h | 0 .../{query => }/test/SetExecutorTest.cpp | 0 src/executor/{query => }/test/SortTest.cpp | 2 +- 15 files changed, 10 insertions(+), 73 deletions(-) delete mode 100644 src/executor/logic/test/CMakeLists.txt rename src/executor/{query => }/test/AggregateTest.cpp (100%) rename src/executor/{query => }/test/CMakeLists.txt (97%) rename src/executor/{query => }/test/DataCollectTest.cpp (100%) rename src/executor/{query => }/test/DataJoinTest.cpp (99%) rename src/executor/{query => }/test/DedupTest.cpp (99%) rename src/executor/{query => }/test/FilterTest.cpp (99%) rename src/executor/{query => }/test/GetNeighborsTest.cpp (100%) rename src/executor/{query => }/test/LimitTest.cpp (99%) rename src/executor/{logic => }/test/LogicExecutorsTest.cpp (100%) rename src/executor/{query => }/test/ProjectTest.cpp (98%) rename src/executor/{query => }/test/QueryTestBase.h (100%) rename src/executor/{query => }/test/SetExecutorTest.cpp (100%) rename src/executor/{query => }/test/SortTest.cpp (99%) diff --git a/src/executor/CMakeLists.txt b/src/executor/CMakeLists.txt index 7c4c5ff485d..6aa9c20cfdc 100644 --- a/src/executor/CMakeLists.txt +++ b/src/executor/CMakeLists.txt @@ -55,5 +55,4 @@ nebula_add_library( admin/ConfigExecutor.cpp ) -nebula_add_subdirectory(query/test) -nebula_add_subdirectory(logic/test) +nebula_add_subdirectory(test) diff --git a/src/executor/logic/test/CMakeLists.txt b/src/executor/logic/test/CMakeLists.txt deleted file mode 100644 index de35a2cb054..00000000000 --- a/src/executor/logic/test/CMakeLists.txt +++ /dev/null @@ -1,62 +0,0 @@ -# Copyright (c) 2020 vesoft inc. All rights reserved. -# -# This source code is licensed under Apache 2.0 License, -# attached with Common Clause Condition 1.0, found in the LICENSES directory. - -SET(EXEC_LOGIC_TEST_LIBS - $ - $ - $ - $ - $ - $ - $ - $ - $ - $ - $ - $ - $ - $ - $ - $ - $ - $ - $ - $ - $ - $ - $ - $ - $ - $ - $ - $ - $ - $ - $ - $ - $ - $ - $ - $ - $ - $ - $ - $ -) - -nebula_add_test( - NAME logic_executors_test - SOURCES - LogicExecutorsTest.cpp - OBJECTS - ${EXEC_LOGIC_TEST_LIBS} - LIBRARIES - ${THRIFT_LIBRARIES} - gtest - gtest_main - wangle - proxygenhttpserver - proxygenlib -) diff --git a/src/executor/query/test/AggregateTest.cpp b/src/executor/test/AggregateTest.cpp similarity index 100% rename from src/executor/query/test/AggregateTest.cpp rename to src/executor/test/AggregateTest.cpp diff --git a/src/executor/query/test/CMakeLists.txt b/src/executor/test/CMakeLists.txt similarity index 97% rename from src/executor/query/test/CMakeLists.txt rename to src/executor/test/CMakeLists.txt index 9190764c426..bde096880ac 100644 --- a/src/executor/query/test/CMakeLists.txt +++ b/src/executor/test/CMakeLists.txt @@ -4,7 +4,6 @@ # attached with Common Clause Condition 1.0, found in the LICENSES directory. SET(EXEC_QUERY_TEST_OBJS - $ $ $ $ @@ -15,12 +14,12 @@ SET(EXEC_QUERY_TEST_OBJS $ $ $ + $ $ $ $ $ $ - $ $ $ $ @@ -57,8 +56,9 @@ SET(EXEC_QUERY_TEST_LIBS nebula_add_test( NAME - query_executors_test + executor_test SOURCES + LogicExecutorsTest.cpp ProjectTest.cpp GetNeighborsTest.cpp DataCollectTest.cpp diff --git a/src/executor/query/test/DataCollectTest.cpp b/src/executor/test/DataCollectTest.cpp similarity index 100% rename from src/executor/query/test/DataCollectTest.cpp rename to src/executor/test/DataCollectTest.cpp diff --git a/src/executor/query/test/DataJoinTest.cpp b/src/executor/test/DataJoinTest.cpp similarity index 99% rename from src/executor/query/test/DataJoinTest.cpp rename to src/executor/test/DataJoinTest.cpp index 6b22caf21e2..1557ab4b64d 100644 --- a/src/executor/query/test/DataJoinTest.cpp +++ b/src/executor/test/DataJoinTest.cpp @@ -9,7 +9,7 @@ #include "context/QueryContext.h" #include "planner/Query.h" #include "executor/query/DataJoinExecutor.h" -#include "executor/query/test/QueryTestBase.h" +#include "executor/test/QueryTestBase.h" namespace nebula { namespace graph { diff --git a/src/executor/query/test/DedupTest.cpp b/src/executor/test/DedupTest.cpp similarity index 99% rename from src/executor/query/test/DedupTest.cpp rename to src/executor/test/DedupTest.cpp index f55c4cbbd9d..775c49d4337 100644 --- a/src/executor/query/test/DedupTest.cpp +++ b/src/executor/test/DedupTest.cpp @@ -8,7 +8,7 @@ #include "context/QueryContext.h" #include "planner/Query.h" #include "executor/query/DedupExecutor.h" -#include "executor/query/test/QueryTestBase.h" +#include "executor/test/QueryTestBase.h" #include "executor/query/ProjectExecutor.h" namespace nebula { diff --git a/src/executor/query/test/FilterTest.cpp b/src/executor/test/FilterTest.cpp similarity index 99% rename from src/executor/query/test/FilterTest.cpp rename to src/executor/test/FilterTest.cpp index 4fe0db9c660..d094ef493bf 100644 --- a/src/executor/query/test/FilterTest.cpp +++ b/src/executor/test/FilterTest.cpp @@ -8,7 +8,7 @@ #include "context/QueryContext.h" #include "executor/query/FilterExecutor.h" #include "executor/query/ProjectExecutor.h" -#include "executor/query/test/QueryTestBase.h" +#include "executor/test/QueryTestBase.h" #include "planner/Query.h" #include "util/ExpressionUtils.h" diff --git a/src/executor/query/test/GetNeighborsTest.cpp b/src/executor/test/GetNeighborsTest.cpp similarity index 100% rename from src/executor/query/test/GetNeighborsTest.cpp rename to src/executor/test/GetNeighborsTest.cpp diff --git a/src/executor/query/test/LimitTest.cpp b/src/executor/test/LimitTest.cpp similarity index 99% rename from src/executor/query/test/LimitTest.cpp rename to src/executor/test/LimitTest.cpp index 99e13d92934..f5a6b31c966 100644 --- a/src/executor/query/test/LimitTest.cpp +++ b/src/executor/test/LimitTest.cpp @@ -9,7 +9,7 @@ #include "context/QueryContext.h" #include "executor/query/LimitExecutor.h" #include "executor/query/ProjectExecutor.h" -#include "executor/query/test/QueryTestBase.h" +#include "executor/test/QueryTestBase.h" #include "planner/Logic.h" #include "planner/Query.h" #include "util/ExpressionUtils.h" diff --git a/src/executor/logic/test/LogicExecutorsTest.cpp b/src/executor/test/LogicExecutorsTest.cpp similarity index 100% rename from src/executor/logic/test/LogicExecutorsTest.cpp rename to src/executor/test/LogicExecutorsTest.cpp diff --git a/src/executor/query/test/ProjectTest.cpp b/src/executor/test/ProjectTest.cpp similarity index 98% rename from src/executor/query/test/ProjectTest.cpp rename to src/executor/test/ProjectTest.cpp index fbd99c5c4a1..c1ee6e607bb 100644 --- a/src/executor/query/test/ProjectTest.cpp +++ b/src/executor/test/ProjectTest.cpp @@ -8,7 +8,7 @@ #include "context/QueryContext.h" #include "executor/query/ProjectExecutor.h" -#include "executor/query/test/QueryTestBase.h" +#include "executor/test/QueryTestBase.h" #include "planner/Logic.h" #include "planner/Query.h" diff --git a/src/executor/query/test/QueryTestBase.h b/src/executor/test/QueryTestBase.h similarity index 100% rename from src/executor/query/test/QueryTestBase.h rename to src/executor/test/QueryTestBase.h diff --git a/src/executor/query/test/SetExecutorTest.cpp b/src/executor/test/SetExecutorTest.cpp similarity index 100% rename from src/executor/query/test/SetExecutorTest.cpp rename to src/executor/test/SetExecutorTest.cpp diff --git a/src/executor/query/test/SortTest.cpp b/src/executor/test/SortTest.cpp similarity index 99% rename from src/executor/query/test/SortTest.cpp rename to src/executor/test/SortTest.cpp index 043ed23d9a5..c4bed04e8f3 100644 --- a/src/executor/query/test/SortTest.cpp +++ b/src/executor/test/SortTest.cpp @@ -9,7 +9,7 @@ #include "context/QueryContext.h" #include "executor/query/ProjectExecutor.h" #include "executor/query/SortExecutor.h" -#include "executor/query/test/QueryTestBase.h" +#include "executor/test/QueryTestBase.h" #include "planner/Logic.h" #include "planner/Query.h"