jstests/aggregation/optimize_away_pipeline.js
// Test that getMore works with the optimized query.
Test that getMore works with the optimized query.
Test that getMore works with the optimized query .
function testGetMore({command = null, expectedResult = null} = {}) {
    const documents =
        new DBCommandCursor(db, assert.commandWorked(db.runCommand(command)), 1 )
            .toArray();
    assert.sameMembers(documents, expectedResult);
}
function testGetMore ( { command = null , expectedResult = null } = { } ) { const documents = new DBCommandCursor ( db , assert . commandWorked ( db . runCommand ( command ) ) , 1 ) . toArray ( ) ; assert . sameMembers ( documents , expectedResult ) ; }
Test that getMore works with the optimized query.
Test that getMore works with the optimized query .
/* batchsize */