Skip to content

Commit c7c5e14

Browse files
committed
docs: fix examples for disconnect
Related: #201 (comment)
1 parent 5fc1652 commit c7c5e14

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

README.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -363,9 +363,9 @@ before((done) => {
363363
.then(() => done());
364364
});
365365

366-
after(() => {
367-
mongoose.disconnect();
368-
mongoServer.stop();
366+
after(async () => {
367+
await mongoose.disconnect();
368+
await mongoServer.stop();
369369
});
370370

371371
describe('...', () => {
@@ -398,7 +398,7 @@ beforeAll(async () => {
398398
});
399399

400400
afterAll(async () => {
401-
mongoose.disconnect();
401+
await mongoose.disconnect();
402402
await mongoServer.stop();
403403
});
404404

0 commit comments

Comments
 (0)