summaryrefslogtreecommitdiff
path: root/jstests
diff options
context:
space:
mode:
authorLouis Williams <louis.williams@mongodb.com>2019-01-22 17:29:55 -0500
committerLouis Williams <louis.williams@mongodb.com>2019-02-06 13:04:21 -0500
commitbb69551adf200b1b050476ad01b765018d5bac80 (patch)
tree929f508105697e1d90ae84b93bbc549c0b853975 /jstests
parent33b153224e08a213f505c4f9e85d087d713cae5a (diff)
downloadmongo-bb69551adf200b1b050476ad01b765018d5bac80.tar.gz
SERVER-38986 Timestamp writes while draining
Diffstat (limited to 'jstests')
-rw-r--r--jstests/noPassthrough/hybrid_unique_index_with_updates.js12
1 files changed, 8 insertions, 4 deletions
diff --git a/jstests/noPassthrough/hybrid_unique_index_with_updates.js b/jstests/noPassthrough/hybrid_unique_index_with_updates.js
index b3dc94ca4fd..7aa7bbe21f2 100644
--- a/jstests/noPassthrough/hybrid_unique_index_with_updates.js
+++ b/jstests/noPassthrough/hybrid_unique_index_with_updates.js
@@ -3,14 +3,18 @@
* of hybrid unique index builds. This test inserts a duplicate document at different phases of an
* index build to confirm that the resulting behavior is failure.
*
- * @tags: [requires_document_locking]
+ * @tags: [requires_document_locking, requires_replication]
*/
(function() {
"use strict";
load("jstests/libs/check_log.js");
- let conn = MongoRunner.runMongod();
+ let replSetTest = new ReplSetTest({name: "hybrid_updates", nodes: 2});
+ replSetTest.startSet();
+ replSetTest.initiate();
+
+ let conn = replSetTest.getPrimary();
let testDB = conn.getDB('test');
// Run 'func' while failpoint is enabled.
@@ -53,7 +57,7 @@
/**
* Run a background index build on a unique index under different configurations. Introduce
* duplicate keys on the index that may cause it to fail or succeed, depending on the following
- * optional parmeters:
+ * optional parameters:
* {
* // Which operation used to introduce a duplicate key.
* operation {string}: "insert", "update"
@@ -153,5 +157,5 @@
runTest({operation: "update", resolve: false, phase: i});
}
- MongoRunner.stopMongod(conn);
+ replSetTest.stopSet();
})();