Skip to content

Instantly share code, notes, and snippets.

@hyzhak
Created May 5, 2014 11:37
Show Gist options
  • Select an option

  • Save hyzhak/71e9ee218c017f9ce4ef to your computer and use it in GitHub Desktop.

Select an option

Save hyzhak/71e9ee218c017f9ce4ef to your computer and use it in GitHub Desktop.
How to fail jasmine 2.0 async spec on fail promise
it('should ....', function(done) {
doAsync().then(function() {
done();
}, function(err) {
//How to fail jasmine 2.0 async spec on fail promise
//done(err || 'error') - doesn't work because 'done' doesn't handle arguments
});
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment