summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJacob Evans <jacob.evans@mongodb.com>2019-10-14 18:46:40 +0000
committerevergreen <evergreen@mongodb.com>2019-10-14 18:46:40 +0000
commitb202ee3df460192bddf4193076c346928457a150 (patch)
treec884ac11ee1d5a2227520701e7bd49e5309e1986
parentedf4ab0f81741a3788e17d2a1009ea935ef639c2 (diff)
downloadmongo-b202ee3df460192bddf4193076c346928457a150.tar.gz
SERVER-43966 Remove manual internal query flag toggling from map_reduce_validation.js
-rw-r--r--buildscripts/resmokeconfig/suites/core_map_reduce_agg.yaml1
-rw-r--r--jstests/core/map_reduce_validation.js22
2 files changed, 7 insertions, 16 deletions
diff --git a/buildscripts/resmokeconfig/suites/core_map_reduce_agg.yaml b/buildscripts/resmokeconfig/suites/core_map_reduce_agg.yaml
index 46732b5cc90..76de071a6e0 100644
--- a/buildscripts/resmokeconfig/suites/core_map_reduce_agg.yaml
+++ b/buildscripts/resmokeconfig/suites/core_map_reduce_agg.yaml
@@ -5,6 +5,7 @@ test_kind: js_test
selector:
roots:
- jstests/core/commands_namespace_parsing.js
+ - jstests/core/map_reduce_validation.js
- jstests/core/mr_index.js
- jstests/core/mr_merge2.js
- jstests/core/mr_mutable_properties.js
diff --git a/jstests/core/map_reduce_validation.js b/jstests/core/map_reduce_validation.js
index 6b3101b62b8..37bc731f9ba 100644
--- a/jstests/core/map_reduce_validation.js
+++ b/jstests/core/map_reduce_validation.js
@@ -90,20 +90,10 @@ assert.commandFailed(db.runCommand({
out: {merge: "foo", db: /test/}
}));
-// The new implementation is not supported in a sharded cluster yet, so avoid running it in the
-// passthrough suites.
-if (!FixtureHelpers.isMongos(db)) {
- // Test that mapReduce fails when run against a view.
- db.sourceView.drop();
- assert.commandWorked(db.createView("sourceView", source.getName(), [{$project: {_id: 0}}]));
- assert.commandFailedWithCode(
- db.runCommand({mapReduce: "sourceView", map: mapFunc, reduce: reduceFunc, out: "foo"}),
- ErrorCodes.CommandNotSupportedOnView);
-
- assert.commandWorked(db.adminCommand({setParameter: 1, internalQueryUseAggMapReduce: true}));
- assert.commandFailedWithCode(
- db.runCommand({mapReduce: "sourceView", map: mapFunc, reduce: reduceFunc, out: "foo"}),
- ErrorCodes.CommandNotSupportedOnView);
- assert.commandWorked(db.adminCommand({setParameter: 1, internalQueryUseAggMapReduce: false}));
-}
+// Test that mapReduce fails when run against a view.
+db.sourceView.drop();
+assert.commandWorked(db.createView("sourceView", source.getName(), [{$project: {_id: 0}}]));
+assert.commandFailedWithCode(
+ db.runCommand({mapReduce: "sourceView", map: mapFunc, reduce: reduceFunc, out: "foo"}),
+ ErrorCodes.CommandNotSupportedOnView);
}());