Fixing afterEach getting called if waitsFor times out #312

wants to merge 1 commit into

2 participants


When a test has runs and waitsFor blocks and one of the waitsFor blocks times out, afterEach does not get called. This can leave the test suite in a bad state.


We've moved away from runs/waitsFor for async on master. We've moved to a done() function, similar to Mocha and others. This was a long standing issue - see - and Pull Request #18.

I've added a story here () to focus on timeout protection being present in 2.0:

closing for now.

@infews infews closed this Mar 4, 2013

Is 2.0 scheduled to be out soon? Because my pull request fixes the the Pull Request #18 that you mentioned which till has issues in the 1.x versions. This pull request fixes a case (and includes the test that shows the problem) missed by that pull request.

I just want to make sure you realize that this pull request fixes an on-going issue in 1.x versions. If 2.0 is out soon and 1.x is not to be used, then closing this request is the right action. If 1.x should be fixed, then please apply this.



We don't have a firm release date yet. However, you should be able to play with 2.0 on master right now.

I believe this bug still exists with the new implementation as well, though there's a story for it in Tracker.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment