Close to prevent hangs
This commit is contained in:
parent
7901a46721
commit
a8b1e40a1e
@ -96,6 +96,12 @@ class Database {
|
||||
}
|
||||
}
|
||||
|
||||
async close() {
|
||||
this.validate();
|
||||
this.db.close();
|
||||
this.db = null;
|
||||
}
|
||||
|
||||
async purge() {
|
||||
this.validate();
|
||||
|
||||
|
@ -130,6 +130,8 @@ async function testDatabase1() {
|
||||
// Cleanup
|
||||
await cleanup();
|
||||
}
|
||||
|
||||
await database.close();
|
||||
}
|
||||
|
||||
async function testDatabaseEmpty1(database) {
|
||||
|
Loading…
Reference in New Issue
Block a user