diff options
author | Gregory Wlodarek <gregory.wlodarek@mongodb.com> | 2019-04-04 08:02:40 -0400 |
---|---|---|
committer | Gregory Wlodarek <gregory.wlodarek@mongodb.com> | 2019-04-04 08:02:40 -0400 |
commit | e6abd76d9ca9e03256ceadda7d9eb54994239b42 (patch) | |
tree | a99f743e3cf7f39a9bee51504c32d54053a0b92a /jstests/readonly | |
parent | 4459b439700f096a7b6287fdddde592db8934fe2 (diff) | |
download | mongo-e6abd76d9ca9e03256ceadda7d9eb54994239b42.tar.gz |
SERVER-40345 Change calls involving the 'temp' field in the 'create' command to be done through the 'applyOps' command
Diffstat (limited to 'jstests/readonly')
-rw-r--r-- | jstests/readonly/temp_collection.js | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/jstests/readonly/temp_collection.js b/jstests/readonly/temp_collection.js index 9c24b5ed4ef..5f32d723b71 100644 --- a/jstests/readonly/temp_collection.js +++ b/jstests/readonly/temp_collection.js @@ -1,5 +1,6 @@ // Tests that the server is able to restart in read-only mode with data files that contain one or // more temporary collections. See SERVER-24719 for details. +// @tags: [requires_replication] 'use strict'; load('jstests/readonly/lib/read_only_test.js'); @@ -13,7 +14,13 @@ runReadOnlyTest((function() { var writableDB = writableCollection.getDB(); writableDB[collName].drop(); - assert.commandWorked(writableDB.createCollection(collName, {temp: true})); + assert.commandWorked(writableDB.runCommand({ + applyOps: [{ + op: "c", + ns: writableDB.getName() + ".$cmd", + o: {create: collName, temp: true} + }] + })); var collectionInfos = writableDB.getCollectionInfos(); var collectionExists = false; |