diff options
author | Randolph Tan <randolph@10gen.com> | 2014-04-25 14:04:36 -0400 |
---|---|---|
committer | Randolph Tan <randolph@10gen.com> | 2014-05-06 16:32:44 -0400 |
commit | 87dc3ae516e1d12a632dc604710661e38ed7b3dd (patch) | |
tree | 3a483a3d0c38ce00a7f4d7dba0e9cba7f7eba5f3 /jstests/noPassthroughWithMongod/capped4.js | |
parent | 6b945ec15c61f6bd4bfbaf382624d886ec8441d2 (diff) | |
download | mongo-87dc3ae516e1d12a632dc604710661e38ed7b3dd.tar.gz |
SERVER-13741 Migrate remaining tests to use write commands
Diffstat (limited to 'jstests/noPassthroughWithMongod/capped4.js')
-rw-r--r-- | jstests/noPassthroughWithMongod/capped4.js | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/jstests/noPassthroughWithMongod/capped4.js b/jstests/noPassthroughWithMongod/capped4.js index 27d138c16ce..be02e3c6ae1 100644 --- a/jstests/noPassthroughWithMongod/capped4.js +++ b/jstests/noPassthroughWithMongod/capped4.js @@ -22,8 +22,8 @@ assert( !d.hasNext(), "C" ); assert( t.find().sort( { i : 1 } ).hint( { i : 1 } ).toArray().length > 10, "D" ); assert( t.findOne( { i : i - 1 } ), "E" ); -t.remove( { i : i - 1 } ); -assert( db.getLastError().indexOf( "capped" ) >= 0, "F" ); +var res = assert.writeError(t.remove( { i : i - 1 } )); +assert( res.getWriteError().errmsg.indexOf( "capped" ) >= 0, "F" ); assert( t.validate().valid, "G" );
|