Skip to content

Commit ac65818

Browse files
authored
Merge pull request #16 from golopot/fix-test
Fix test not ending properly
2 parents c9600b5 + a59992b commit ac65818

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

test.js

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,10 @@ function runTests () {
2121
const client = AsyncMQTT.connect(SERVER_URL);
2222

2323
t.ok(client instanceof AsyncClient, 'Connect returned an AsyncClient');
24-
client.end();
24+
25+
client.on('connect', () => {
26+
client.end();
27+
})
2528
});
2629

2730
test('Should be able to listen on event on client', t => {

0 commit comments

Comments
 (0)