Skip to content

Commit 68f2a88

Browse files
author
Ruben Bridgewater
committed
Make test more robust
The redis server ends the connection and the stream end might be triggered before the quit command returned and is therefor racy.
1 parent 1a884a8 commit 68f2a88

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

test/multi.spec.js

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -101,9 +101,8 @@ describe("The 'multi' method", function () {
101101
beforeEach(function (done) {
102102
client = redis.createClient.apply(null, args);
103103
client.once('ready', function () {
104-
client.quit();
104+
client.quit(done);
105105
});
106-
client.once('end', done);
107106
});
108107

109108
it('reports an error', function (done) {

0 commit comments

Comments
 (0)