blob: e44d3cfb70e9838f52fba1a2209d853071734f44 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
|
// Test that attempting to read after optime fails if replication is not enabled.
(function() {
"use strict";
var currentTime = new Date();
var futureOpTime = new Timestamp((currentTime / 1000 + 3600), 0);
assert.commandFailedWithCode(
db.runCommand(
{find: 'user', filter: {x: 1}, readConcern: {afterOpTime: {ts: futureOpTime, t: 0}}}),
ErrorCodes.NotAReplicaSet);
})();
|