Skip to content

Commit 9224614

Browse files
authored
Merge pull request #14096 from Automattic/vkarpov15/gh-13970
test(query): remove unnecessary query test code
2 parents 34d045f + 782db45 commit 9224614

File tree

1 file changed

+1
-11
lines changed

1 file changed

+1
-11
lines changed

test/query.test.js

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1373,7 +1373,7 @@ describe('Query', function() {
13731373
});
13741374

13751375
describe('setOptions', function() {
1376-
it('works', async function() {
1376+
it('works', function() {
13771377
const q = new Query();
13781378
q.setOptions({ thing: 'cat' });
13791379
q.setOptions({ populate: ['fans'] });
@@ -1397,16 +1397,6 @@ describe('Query', function() {
13971397
assert.equal(q.options.hint.index2, -1);
13981398
assert.equal(q.options.readPreference.mode, 'secondary');
13991399
assert.equal(q.options.readPreference.tags[0].dc, 'eu');
1400-
1401-
const Product = db.model('Product', productSchema);
1402-
const [, doc2] = await Product.create([
1403-
{ numbers: [3, 4, 5] },
1404-
{ strings: 'hi there'.split(' '), w: 'majority' }
1405-
]);
1406-
1407-
const docs = await Product.find().setOptions({ limit: 1, sort: { _id: -1 }, read: 'n' });
1408-
assert.equal(docs.length, 1);
1409-
assert.equal(docs[0].id, doc2.id);
14101400
});
14111401

14121402
it('populate as array in options (gh-4446)', function() {

0 commit comments

Comments
 (0)