Skip to content

Commit 495362e

Browse files
committed
linter fixes
1 parent 02890da commit 495362e

File tree

1 file changed

+21
-7
lines changed

1 file changed

+21
-7
lines changed

test/integration/crud/misc_cursors.test.ts

Lines changed: 21 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -168,7 +168,9 @@ describe('Cursor', function () {
168168
count = await cursor.count();
169169
test.equal(10, count);
170170

171-
await cursor.forEach(() => { });
171+
await cursor.forEach(() => {
172+
// do nothing
173+
});
172174

173175
const count2 = await cursor.count();
174176
expect(count2).to.equal(10);
@@ -240,7 +242,9 @@ describe('Cursor', function () {
240242
count = await cursor.count();
241243
test.equal(10, count);
242244

243-
await cursor.forEach(() => { });
245+
await cursor.forEach(() => {
246+
// do nothing
247+
});
244248

245249
const count2 = await cursor.count();
246250
expect(count2).to.equal(10);
@@ -1447,7 +1451,9 @@ describe('Cursor', function () {
14471451
const cursor = collection.find({}, { tailable: true, awaitData: true });
14481452
// this.defer(() => cursor.close());
14491453

1450-
await cursor.forEach(() => { });
1454+
await cursor.forEach(() => {
1455+
// do nothing
1456+
});
14511457
await cursor.close();
14521458
await client.close();
14531459
});
@@ -1475,7 +1481,7 @@ describe('Cursor', function () {
14751481
try {
14761482
await db.collection('cursor_tailable').drop();
14771483
// eslint-disable-next-line no-empty
1478-
} catch { }
1484+
} catch {}
14791485

14801486
const collection = await db.createCollection('cursor_tailable', {
14811487
capped: true,
@@ -1923,7 +1929,11 @@ describe('Cursor', function () {
19231929
await collection.insertMany(docs, configuration.writeConcernMax());
19241930

19251931
const cursor = collection.find({}, { tailable: true });
1926-
const err = await cursor.forEach(() => { }).catch(e => e);
1932+
const err = await cursor
1933+
.forEach(() => {
1934+
// do nothing
1935+
})
1936+
.catch(e => e);
19271937
test.ok(err instanceof Error);
19281938
test.ok(typeof err.code === 'number');
19291939

@@ -2694,7 +2704,9 @@ describe('Cursor', function () {
26942704

26952705
const configuration = this.configuration;
26962706

2697-
const cleanup = () => { };
2707+
const cleanup = () => {
2708+
// do nothing
2709+
};
26982710
let caughtError = undefined;
26992711

27002712
return (
@@ -2914,7 +2926,9 @@ describe('Cursor', function () {
29142926
const cursor = collection.find();
29152927
this.defer(() => cursor.close());
29162928

2917-
const promise = cursor.forEach(() => { });
2929+
const promise = cursor.forEach(() => {
2930+
// do nothing
2931+
});
29182932
expect(promise).to.exist.and.to.be.an.instanceof(Promise);
29192933
return promise;
29202934
});

0 commit comments

Comments
 (0)