diff options
author | Mark Benvenuto <mark.benvenuto@mongodb.com> | 2016-05-28 17:55:12 -0400 |
---|---|---|
committer | Mark Benvenuto <mark.benvenuto@mongodb.com> | 2016-05-28 17:55:12 -0400 |
commit | 6dcdd23dd37ef12c87e71cf59ef01cd82432efe0 (patch) | |
tree | c8cfb5acb62c80f375bc37e7d4350382deea6a37 /src/mongo/db/matcher/expression_algo_test.cpp | |
parent | d4ac5673ea3f6cef4ce9dbcec90e31813997a528 (diff) | |
download | mongo-6dcdd23dd37ef12c87e71cf59ef01cd82432efe0.tar.gz |
SERVER-23971 Clang-Format code
Diffstat (limited to 'src/mongo/db/matcher/expression_algo_test.cpp')
-rw-r--r-- | src/mongo/db/matcher/expression_algo_test.cpp | 23 |
1 files changed, 12 insertions, 11 deletions
diff --git a/src/mongo/db/matcher/expression_algo_test.cpp b/src/mongo/db/matcher/expression_algo_test.cpp index 73d3a5b8b88..95e7bcd62fc 100644 --- a/src/mongo/db/matcher/expression_algo_test.cpp +++ b/src/mongo/db/matcher/expression_algo_test.cpp @@ -73,9 +73,10 @@ TEST(ExpressionAlgoIsSubsetOf, NullAndOmittedField) { // an Undefined type. BSONObj undefined = fromjson("{a: undefined}"); const CollatorInterface* collator = nullptr; - ASSERT_EQUALS(ErrorCodes::BadValue, - MatchExpressionParser::parse( - undefined, ExtensionsCallbackDisallowExtensions(), collator).getStatus()); + ASSERT_EQUALS( + ErrorCodes::BadValue, + MatchExpressionParser::parse(undefined, ExtensionsCallbackDisallowExtensions(), collator) + .getStatus()); ParsedMatchExpression empty("{}"); ParsedMatchExpression null("{a: null}"); @@ -839,11 +840,11 @@ TEST(SplitMatchExpression, ComplexMatchExpressionSplitsCorrectly) { splitExpr.second->serialize(&secondBob); ASSERT_EQUALS(firstBob.obj(), fromjson("{$or: [{'a.b': {$eq: 3}}, {'a.b.c': {$eq: 4}}]}")); - ASSERT_EQUALS(secondBob.obj(), - fromjson( - "{$and: [{$nor: [{$and: [{x: {$size: 2}}]}]}, {$nor: [{x: {$gt: 4}}, {$and: " - "[{$nor: [{$and: [{x: " - "{$eq: 1}}]}]}, {y: {$eq: 3}}]}]}]}")); + ASSERT_EQUALS( + secondBob.obj(), + fromjson("{$and: [{$nor: [{$and: [{x: {$size: 2}}]}]}, {$nor: [{x: {$gt: 4}}, {$and: " + "[{$nor: [{$and: [{x: " + "{$eq: 1}}]}]}, {y: {$eq: 3}}]}]}]}")); } TEST(MapOverMatchExpression, DoesMapOverLogicalNodes) { @@ -909,9 +910,9 @@ TEST(MapOverMatchExpression, DoesMapOverNodesWithMultipleChildren) { ASSERT_OK(swMatchExpression.getStatus()); size_t nodeCount = 0; - expression::mapOver(swMatchExpression.getValue().get(), - [&nodeCount](MatchExpression* expression, std::string path) - -> void { ++nodeCount; }); + expression::mapOver( + swMatchExpression.getValue().get(), + [&nodeCount](MatchExpression* expression, std::string path) -> void { ++nodeCount; }); ASSERT_EQ(nodeCount, 3U); } |