(function() {
|
const rst = ReplSetTest({nodes: 1});
|
rst.startSet();
|
rst.initiate();
|
|
const testDB = rst.getPrimary().getDB("test");
|
const session = testDB.getMongo().startSession({causalConsistency: false});
|
const sessionDB = session.getDatabase("test");
|
assert.commandWorked(sessionDB.c.insert({}));
|
|
session.startTransaction();
|
assert.commandWorked(sessionDB.c.insert({}));
|
|
// Runs forever.
|
assert.commandFailedWithCode(testDB.runCommand({dropDatabase: 1, maxTimeMS: 100}), ErrorCodes.ExceededTimeLimit);
|
|
session.commitTransaction();
|
session.endSession();
|
rst.stopSet();
|
}());
|