Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

after/afterEach aren't called when a test fails when using --bail #1093

Closed
travisjeffery opened this issue Jan 1, 2014 · 7 comments
Closed
Labels
type: bug a defect, confirmed by a maintainer

Comments

@travisjeffery
Copy link
Contributor

No description provided.

@alfredwesterveld
Copy link

+1? This cleanup should be done?

@aronwoost
Copy link

+1

Even when thing fail with --bail, we need to cleanup. Don't we?

@drawveloper
Copy link

I can also confirm this... Unfortunately, --bail is useless while this bug exists.

@whitfin
Copy link

whitfin commented Oct 17, 2014

+1 to the comment left by @Gadr. --bail is not a possibility if you cannot guarantee cleanup after the test.

@esamattis
Copy link

Others have suggested doing clean up in the before hooks which I agree but it is just not possible in all cases. For example when using Selenium with the the wd module I like to close the browser after tests but that's not possible in the before hook because the connection to the browser is lost.

And in the same use case I want to use --bail because my it clauses always depend on the previous one (Selenium is just too slow to run as isolated steps).

@whitfin
Copy link

whitfin commented Oct 31, 2014

@epeli that's exactly my use case too :)

@dasilvacontin
Copy link
Contributor

PR sent!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: bug a defect, confirmed by a maintainer
Projects
None yet
Development

No branches or pull requests

7 participants