Skip to content

Commit

Permalink
Lookup sentence (vesoft-inc#1705)
Browse files Browse the repository at this point in the history
  • Loading branch information
bright-starry-sky authored Feb 19, 2020
1 parent 812655d commit 430ca71
Show file tree
Hide file tree
Showing 20 changed files with 1,797 additions and 116 deletions.
9 changes: 9 additions & 0 deletions src/common/base/test/NebulaKeyUtilsTest.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,15 @@ TEST(NebulaKeyUtilsTest, encodeVariant) {
EXPECT_TRUE(evalDouble(-(0.000000001 - std::numeric_limits<double>::min())));
}

TEST(NebulaKeyUtilsTest, encodeDouble) {
EXPECT_TRUE(evalDouble(100.5));
EXPECT_TRUE(evalDouble(200.5));
EXPECT_TRUE(evalDouble(300.5));
EXPECT_TRUE(evalDouble(400.5));
EXPECT_TRUE(evalDouble(500.5));
EXPECT_TRUE(evalDouble(600.5));
}

} // namespace nebula


Expand Down
2 changes: 1 addition & 1 deletion src/graph/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,6 @@ nebula_add_library(
FetchEdgesExecutor.cpp
FetchExecutor.cpp
SetExecutor.cpp
FindExecutor.cpp
MatchExecutor.cpp
DeleteVertexExecutor.cpp
DeleteEdgesExecutor.cpp
Expand All @@ -62,6 +61,7 @@ nebula_add_library(
CreateSnapshotExecutor.cpp
DropSnapshotExecutor.cpp
AdminJobExecutor.cpp
LookupExecutor.cpp
)
nebula_add_subdirectory(test)

6 changes: 3 additions & 3 deletions src/graph/Executor.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@
#include "graph/FetchEdgesExecutor.h"
#include "graph/ConfigExecutor.h"
#include "graph/SetExecutor.h"
#include "graph/FindExecutor.h"
#include "graph/LookupExecutor.h"
#include "graph/MatchExecutor.h"
#include "graph/BalanceExecutor.h"
#include "graph/DeleteVertexExecutor.h"
Expand Down Expand Up @@ -175,8 +175,8 @@ std::unique_ptr<Executor> Executor::makeExecutor(Sentence *sentence) {
case Sentence::Kind::kMatch:
executor = std::make_unique<MatchExecutor>(sentence, ectx());
break;
case Sentence::Kind::kFind:
executor = std::make_unique<FindExecutor>(sentence, ectx());
case Sentence::Kind::kLookup:
executor = std::make_unique<LookupExecutor>(sentence, ectx());
break;
case Sentence::Kind::kBalance:
executor = std::make_unique<BalanceExecutor>(sentence, ectx());
Expand Down
24 changes: 0 additions & 24 deletions src/graph/FindExecutor.cpp

This file was deleted.

40 changes: 0 additions & 40 deletions src/graph/FindExecutor.h

This file was deleted.

Loading

0 comments on commit 430ca71

Please sign in to comment.