diff --git a/jstests/core/txns/write_conflicts_with_non_txns.js b/jstests/core/txns/write_conflicts_with_non_txns.js
|
index aeafbc870c..0c2558dbc2 100644
|
--- a/jstests/core/txns/write_conflicts_with_non_txns.js
|
+++ b/jstests/core/txns/write_conflicts_with_non_txns.js
|
@@ -58,7 +58,8 @@ function singleDocWrite(dbName, collName, doc) {
|
|
// Returns true if a single document insert has started running on the server.
|
function writeStarted() {
|
- return testDB.currentOp().inprog.some(op => {
|
+ return testDB.getSiblingDB("admin").aggregate([{$currentOp: {allUsers: false}}]).toArray().some(op => {
|
+ jsTest.log(op);
|
return op.active && (op.ns === testColl.getFullName()) && (op.op === "insert") &&
|
(op.writeConflicts > 0);
|
});
|