summaryrefslogtreecommitdiff
path: root/src/mongo/db/ops/modifier_pop_test.cpp
diff options
context:
space:
mode:
authorScott Hernandez <scotthernandez@gmail.com>2013-08-01 16:00:24 -0400
committerScott Hernandez <scotthernandez@gmail.com>2013-08-01 16:17:26 -0400
commit869557aabbd8837ec86a852957f24ea76e8e13e4 (patch)
tree6a5c78b7278b5ab24fe8fd87d597228af62fb7c5 /src/mongo/db/ops/modifier_pop_test.cpp
parent5647c97e2b618144801c75651f59010088823810 (diff)
downloadmongo-869557aabbd8837ec86a852957f24ea76e8e13e4.tar.gz
SERVER-10163: don't enforce viable path restriction for replication related updates ($set)
Diffstat (limited to 'src/mongo/db/ops/modifier_pop_test.cpp')
-rw-r--r--src/mongo/db/ops/modifier_pop_test.cpp12
1 files changed, 8 insertions, 4 deletions
diff --git a/src/mongo/db/ops/modifier_pop_test.cpp b/src/mongo/db/ops/modifier_pop_test.cpp
index f1fedd08993..9cd04eaa926 100644
--- a/src/mongo/db/ops/modifier_pop_test.cpp
+++ b/src/mongo/db/ops/modifier_pop_test.cpp
@@ -48,7 +48,8 @@ namespace {
explicit Mod(BSONObj modObj) {
_modObj = modObj;
- ASSERT_OK(_mod.init(_modObj["$pop"].embeddedObject().firstElement()));
+ ASSERT_OK(_mod.init(_modObj["$pop"].embeddedObject().firstElement(),
+ ModifierInterface::Options::normal()));
}
Status prepare(Element root,
@@ -81,19 +82,22 @@ namespace {
TEST(Init, StringArg) {
BSONObj modObj = fromjson("{$pop: {a: 'hi'}}");
ModifierPop mod;
- ASSERT_OK(mod.init(modObj["$pop"].embeddedObject().firstElement()));
+ ASSERT_OK(mod.init(modObj["$pop"].embeddedObject().firstElement(),
+ ModifierInterface::Options::normal()));
}
TEST(Init, BoolTrueArg) {
BSONObj modObj = fromjson("{$pop: {a: true}}");
ModifierPop mod;
- ASSERT_OK(mod.init(modObj["$pop"].embeddedObject().firstElement()));
+ ASSERT_OK(mod.init(modObj["$pop"].embeddedObject().firstElement(),
+ ModifierInterface::Options::normal()));
}
TEST(Init, BoolFalseArg) {
BSONObj modObj = fromjson("{$pop: {a: false}}");
ModifierPop mod;
- ASSERT_OK(mod.init(modObj["$pop"].embeddedObject().firstElement()));
+ ASSERT_OK(mod.init(modObj["$pop"].embeddedObject().firstElement(),
+ ModifierInterface::Options::normal()));
}
TEST(MissingField, AllButApply) {