Skip to content

Commit 9ffc5e2

Browse files
committed
chore: drop collections
1 parent 3b1654e commit 9ffc5e2

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

test/integration/collection-management/view.test.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,8 @@ describe('Views', function () {
77
let db: Db;
88

99
beforeEach(async function () {
10-
const configuration = this.configuration;
1110
client = this.configuration.newClient();
12-
db = client.db(configuration.db);
11+
db = client.db('views');
1312
});
1413

1514
afterEach(async function () {

test/integration/shared.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,8 @@ async function setupDatabase(configuration, dbsToClean) {
102102
const db = await client.db(dbName);
103103
for await (const { name } of db.listCollections({}, { nameOnly: true })) {
104104
const collection = db.collection(name);
105-
await collection.deleteMany({});
105+
await collection.deleteMany({}).catch(() => null);
106+
await collection.drop().catch(() => null);
106107
}
107108
}
108109
} finally {

0 commit comments

Comments
 (0)