diff options
author | Pawel Terlecki <pawel.terlecki@mongodb.com> | 2020-06-08 19:41:12 -0400 |
---|---|---|
committer | Evergreen Agent <no-reply@evergreen.mongodb.com> | 2020-06-11 22:16:43 +0000 |
commit | 41fd8b2a5b227dda18ab81da51e10ecafcf64a52 (patch) | |
tree | b5fd15ce19f51b02d2cbcb905f12e9dc32c511f7 /jstests/noPassthroughWithMongod | |
parent | a470fda78b89e8eee045ff76a7fed44da8f6700c (diff) | |
download | mongo-41fd8b2a5b227dda18ab81da51e10ecafcf64a52.tar.gz |
SERVER-46716: Add tests for let parameters for sharded update
Made cosmetic changes for the sake of consistency.
Diffstat (limited to 'jstests/noPassthroughWithMongod')
-rw-r--r-- | jstests/noPassthroughWithMongod/command_let_variables.js | 19 |
1 files changed, 0 insertions, 19 deletions
diff --git a/jstests/noPassthroughWithMongod/command_let_variables.js b/jstests/noPassthroughWithMongod/command_let_variables.js index 42f5ee4c2fc..8c5af176046 100644 --- a/jstests/noPassthroughWithMongod/command_let_variables.js +++ b/jstests/noPassthroughWithMongod/command_let_variables.js @@ -217,23 +217,4 @@ result = db.runCommand({ new: true }); assert.eq(result.value, {Species: "not_a_bird", suspect: "dino"}, result); - -// Update -assert.commandWorked(db.runCommand({ - update: coll.getName(), - let : {target_species: "Song Thrush (Turdus philomelos)", new_name: "Song Thrush"}, - updates: [ - {q: {$expr: {$eq: ["$Species", "$$target_species"]}}, u: [{$set: {Species: "$$new_name"}}]} - ] -})); - -assert.commandWorked(db.runCommand({ - update: coll.getName(), - let : {target_species: "Song Thrush (Turdus philomelos)"}, - updates: [{ - q: {$expr: {$eq: ["$Species", "$$target_species"]}}, - u: [{$set: {Location: "$$place"}}], - c: {place: "North America"} - }] -})); }()); |