Last active
January 25, 2016 05:06
-
-
Save esamattis/1c212ca9d8e29d424e54 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
"use strict"; | |
var Promise = require("bluebird"); | |
describe("ES7 async functions in Mocha", function() { | |
it("are really cool!", async function(){ | |
console.log("waiting..."); | |
await Promise.delay(1000); | |
console.log("done"); | |
}); | |
}); |
Cool :)
Yay
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Async function works here because it returns a promise and mocha supports promises out of the box