Skip to content

Errors during test setup cause phantomjs process to become orphaned #14

@rylnd

Description

@rylnd

Doing something like this:

beforeEach ->
  page = gozer.visit('/')
  throw new Error('little orphan phannie')

leaves the underlying phantomjs process orphaned.

I think that this is due to mocha's handling of asynchonous tests. The fact that we're not returning a promise from the before hooks means that it's not waiting for them to finish. Thus, when an error is thrown, mocha doesn't know about the async stuff that's running, and thus doesn't think it has to kill anything else. That's just speculation, though, I have to dig a little deeper.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions