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

t.bailout results in a hang #21

Closed
trentm opened this issue Nov 30, 2011 · 2 comments
Closed

t.bailout results in a hang #21

trentm opened this issue Nov 30, 2011 · 2 comments

Comments

@trentm
Copy link
Contributor

trentm commented Nov 30, 2011

The following hangs:

$ ../bin/node --version
v0.4.12
$ cat foo.test.js
var test = require('tap').test;
test("first", function(t) {
    t.end();
});
test("bail", function(t) {
    t.bailout("boom");
    t.end();
});
test("last", function(t) {
    t.end();
});
$ ../bin/node foo.test.js
# first
^C

I see this with both tap 0.0.14 and 0.0.1. My understanding from the example test file is that this should abort all subsequent tests in the test file.

@isaacs
Copy link
Member

isaacs commented Nov 30, 2011

Your understanding is correct. This is a bug.

@bigeasy
Copy link

bigeasy commented Dec 12, 2011

It hangs because the timeout is not cleared. It will hang until the timeout is cleared. Setting no timeout, timeout as infinity, causes the program to end on bailout. The processes exists with no output, but should send with "Bail out!" to let the harness know that things are not good.

@isaacs isaacs closed this as completed in 50ffdab Jan 8, 2012
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants