scottcorgan / tap-out

A different tap parser
MIT License
23 stars 28 forks source link

emit test plans #18

Closed jamestalmage closed 9 years ago

jamestalmage commented 9 years ago

Related: https://github.com/scottcorgan/tap-spec/issues/40

@scottcorgan

I've searched high and low, and can not find a way to determine the exit code of the process piping data to stdinn. I am not sure it exists (I know it does in bash shell, but it does not seem to at the OS level).

The way other tap reporters (i.e. faucet) seem to handle this, is that they look for the plan line (which, as I understand it is required), and then compare what they get.

This implements recognition of the plan line:

1...3

And emits it as an event.

This will allow you to correctly exit with your other reporters. Thanks!

scottcorgan commented 9 years ago

SOOO thankful you did this! Thank you! Haven't had time and this keeps popping up. Published as 1.4.0. Updating tap-spec soon.

jamestalmage commented 9 years ago

Awesome, thanks!

//cc: @sindresorhus @vdemedes

sindresorhus commented 9 years ago

@jamestalmage What does this mean for us now? We're already using the builtin node-tap reporter? Is tap-spec any better?

jamestalmage commented 9 years ago

It means we could go back to tape and maybe get back Node 0.10 Windows tests.

I see no need for this if we stick with tap.

sindresorhus commented 9 years ago

@jamestalmage Oh ok. Let's just stick with what we have right now. It seems to be working fine and I don't want to open the can of worms that is Node.js 0.10 on Windows yet. We can reconsider in the future.