Re: TAP has no exit code
# from Aristotle Pagaltzis # on Sunday 30 March 2008 23:14: Except that the test program might be running at the other end of an HTTP connection. Or at the other end of a serial port. Or the harness might be parsing an archived TAP stream. Or a TAP archive generated offline in batch mode. Or… That's a good point, but what does it have to do with plans? $ perl -e 'use Test::More qw(no_plan); ok(1); die;' 2 /dev/null ok 1 1..1 --Eric -- Turns out the optimal technique is to put it in reverse and gun it. --Steven Squyres (on challenges in interplanetary robot navigation) --- http://scratchcomputing.com ---
Re: TAP has no exit code
Eric Wilhelm wrote: # from Aristotle Pagaltzis # on Sunday 30 March 2008 23:14: Except that the test program might be running at the other end of an HTTP connection. Or at the other end of a serial port. Or the harness might be parsing an archived TAP stream. Or a TAP archive generated offline in batch mode. Or… That's a good point, but what does it have to do with plans? $ perl -e 'use Test::More qw(no_plan); ok(1); die;' 2 /dev/null ok 1 1..1 This will look like a success. $ perl -wle 'use Test::More no_plan; pass(); die; pass()' 2/dev/null ok 1 1..1 This will look like a failure. $ perl -wle 'use Test::More tests = 2; pass(); die; pass()' 2/dev/null 1..2 ok 1 If you can't see the exit code of the test then the plan protects you. There is a TAP proposal to add meta information such as the exit codes. http://testanything.org/wiki/index.php/TAP_meta_information -- Being faith-based doesn't trump reality. -- Bruce Sterling
Re: TAP has no exit code
# from Michael G Schwern # on Sunday 30 March 2008 23:35: There is a TAP proposal to add meta information such as the exit codes. http://testanything.org/wiki/index.php/TAP_meta_information Yay. Can we put 'hostname' in there too? --Eric -- Left to themselves, things tend to go from bad to worse. --Murphy's Corollary --- http://scratchcomputing.com ---
Re: TAP has no exit code
Eric Wilhelm wrote: # from Michael G Schwern # on Sunday 30 March 2008 23:35: There is a TAP proposal to add meta information such as the exit codes. http://testanything.org/wiki/index.php/TAP_meta_information Yay. Can we put 'hostname' in there too? You can put whatever you want in there, the magic of YAML! The scheme of reserving all leading lower case keys seems to be working well for META.yml, I've changed the extension rules to reflect that, but it would be a worthwhile official field. (Note, no fields are required). -- 191. Our Humvees cannot be assembled into a giant battle-robot. -- The 213 Things Skippy Is No Longer Allowed To Do In The U.S. Army http://skippyslist.com/list/