Skip to content


Subversion checkout URL

You can clone with
Download ZIP


promise support for async before/after functions and tests #289

jdc0589 opened this Issue · 2 comments

3 participants


Adding native support for promises in addition to the done() style callbacks for async before/after functions + tests would really improve the test writing/debugging experience for projects that depend on promises more so than node style callbacks. There are plenty of ways to make it work without native support, but nothing would beat it.

before/after functions:
In addition to signaling completion/failure of the before/after, it would be great if a promise returned from a before/after function that was rejected would cause the error passed to the reject handler to be logged to the console, and then fail every test in the immediate suite.

returning a promise from a test would simply signal test completion on resolution, or fail the test on rejection.

Has any of this been discussed or considered before?


:+1: for this. Seems native jasmine done promise doesn't work for now. How do you even test async code in jasmine 2.0 without it?


I'm seeing the same issues. Although done() should work in theory, it doesn't seem happy when used with the Bluebird promise library. Test execution just randomly stops mid-execution, but sometimes, for no apparent reason it works. Seems to be some kind of race condition going on.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.