Skip to content

Commit 1a7a7f7

Browse files
committed
migrate
1 parent 2bd2c3a commit 1a7a7f7

1 file changed

Lines changed: 5 additions & 11 deletions

File tree

test/integration/crud/promise_stats.test.js

Lines changed: 5 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ describe('stats', function () {
1515
}
1616
},
1717

18-
test: function (done) {
18+
test: async function () {
1919
var configuration = this.configuration;
2020
var url = configuration.url();
2121
url =
@@ -24,16 +24,10 @@ describe('stats', function () {
2424
: f('%s?%s', url, 'maxPoolSize=5');
2525

2626
const client = configuration.newClient(url);
27-
client.connect().then(function (client) {
28-
client
29-
.db(configuration.db)
30-
.stats()
31-
.then(function (stats) {
32-
test.ok(stats != null);
33-
34-
client.close(done);
35-
});
36-
});
27+
await client.connect();
28+
const stats = await client.db(configuration.db).stats();
29+
test.notEqual(null, stats);
30+
await client.close();
3731
}
3832
});
3933
});

0 commit comments

Comments
 (0)