diff options
author | Nick Zolnierz <nicholas.zolnierz@mongodb.com> | 2017-07-21 12:23:23 -0400 |
---|---|---|
committer | Nick Zolnierz <nicholas.zolnierz@mongodb.com> | 2017-07-24 20:36:37 -0400 |
commit | f22a10013a0aa26a4ad776e0f69e0ab5d33c5f86 (patch) | |
tree | 13a268adf693fc2a7a656cac1af45d9f0822d348 /src/mongo/db/query/parsed_projection_test.cpp | |
parent | cd64c5cfbd0706b38d52cbf9f772fa08ecd969fc (diff) | |
download | mongo-f22a10013a0aa26a4ad776e0f69e0ab5d33c5f86.tar.gz |
SERVER-30028: Create $alwaysTrue and $alwaysFalse MatchExpressions
Diffstat (limited to 'src/mongo/db/query/parsed_projection_test.cpp')
-rw-r--r-- | src/mongo/db/query/parsed_projection_test.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/mongo/db/query/parsed_projection_test.cpp b/src/mongo/db/query/parsed_projection_test.cpp index 0aa4b4ffc74..fa17165932d 100644 --- a/src/mongo/db/query/parsed_projection_test.cpp +++ b/src/mongo/db/query/parsed_projection_test.cpp @@ -29,6 +29,7 @@ #include "mongo/db/query/parsed_projection.h" #include "mongo/db/json.h" +#include "mongo/db/matcher/expression_always_boolean.h" #include "mongo/db/matcher/expression_parser.h" #include "mongo/db/matcher/extensions_callback_disallow_extensions.h" #include "mongo/unittest/unittest.h" @@ -185,7 +186,7 @@ TEST(ParsedProjectionTest, ValidPositionalOperatorProjections) { // to achieve the same effect. // Projection parser should handle this the same way as an empty path. TEST(ParsedProjectionTest, InvalidPositionalProjectionDefaultPathMatchExpression) { - unique_ptr<MatchExpression> queryMatchExpr(new FalseMatchExpression("")); + unique_ptr<MatchExpression> queryMatchExpr(new AlwaysFalseMatchExpression()); ASSERT(NULL == queryMatchExpr->path().rawData()); ParsedProjection* out = NULL; |