Skip to content

Instantly share code, notes, and snippets.

@thanpolas
Created Feb 13, 2014
Embed
What would you like to do?
How to test a promise returning async method using Mocha
test('test case', function(done) {
promise.method(function(result) {
assert.equal(result.name, 'mocha');
}).then(done, done);
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment