Skip to content

Commit a24ec96

Browse files
author
Jean-Baptiste Richardet
committed
Helper.load return a Promise
In addition to the callback, `helper.load()` now returns a Promise. Closes #42
1 parent fefc9ac commit a24ec96

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

index.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -243,11 +243,11 @@ class NodeTestHelper extends EventEmitter {
243243
} else {
244244
testNode(red);
245245
}
246-
redNodes.loadFlows()
246+
return redNodes.loadFlows()
247247
.then(() => {
248248
redNodes.startFlows();
249249
should.deepEqual(testFlow, redNodes.getFlows().flows);
250-
cb();
250+
if(cb) cb();
251251
});
252252
}
253253

0 commit comments

Comments
 (0)