summaryrefslogtreecommitdiff
path: root/jstests/noPassthrough/read_majority.js
diff options
context:
space:
mode:
authormatt dannenberg <matt.dannenberg@10gen.com>2015-08-17 11:50:40 -0400
committermatt dannenberg <matt.dannenberg@10gen.com>2015-08-19 04:32:54 -0400
commit8f84d60e1615e798a18b99405844f7fb4bb96e50 (patch)
tree927ed2c3a8c207fca2274df798b1860650345293 /jstests/noPassthrough/read_majority.js
parent6be756dd654c03049c094c55cb038b0b3305631b (diff)
downloadmongo-8f84d60e1615e798a18b99405844f7fb4bb96e50.tar.gz
SERVER-19984 Block read committed reads after metadata changes, rather than returning an error
Diffstat (limited to 'jstests/noPassthrough/read_majority.js')
-rw-r--r--jstests/noPassthrough/read_majority.js10
1 files changed, 3 insertions, 7 deletions
diff --git a/jstests/noPassthrough/read_majority.js b/jstests/noPassthrough/read_majority.js
index a69b53f81c3..263e2ad28ab 100644
--- a/jstests/noPassthrough/read_majority.js
+++ b/jstests/noPassthrough/read_majority.js
@@ -9,15 +9,11 @@ var testServer = MongoRunner.runMongod({setParameter: 'testingSnapshotBehaviorIn
var db = testServer.getDB("test");
var t = db.readMajority;
-var errorCodes = {
- CommandNotSupported: 115,
- ReadConcernMajorityNotAvailableYet: 134,
-}
-
function assertNoReadMajoritySnapshotAvailable() {
- var res = t.runCommand('find', {batchSize: 2, readConcern: {level: "majority"}});
+ var res = t.runCommand('find',
+ {batchSize: 2, readConcern: {level: "majority"}, maxTimeMS: 1000});
assert.commandFailed(res);
- assert.eq(res.code, errorCodes.ReadConcernMajorityNotAvailableYet);
+ assert.eq(res.code, ErrorCodes.ExceededTimeLimit);
}
function getReadMajorityCursor() {