On 19 Mar 2007, at 12:51, Geoffrey Young wrote:
it's really hard to wade through the flurry of activity of late, but is the consideration really to alter current TAP to make it look like YAML?

No - it's still TAP but with embedded YAML documents to provide extended machine-readable diagnostic information like this:

   TAP version 13
   1..4
   ok 1 - Input file opened
   not ok 2 - First line of the input valid
     ---
     message: 'First line invalid'
     severity: fail
     data:
       got: 'Flirble'
       expect: 'Fnible'
     ...
   ok 3 - Read the rest of the file
   not ok 4 - Summarized correctly # TODO Not written yet
     ---
     message: "Can't make summary yet"
     severity: todo
     ...

If you cut between --- and ... you still have good 'ol TAP v12.

I know this came up here before, and I thought there was a general
consensus that YAML is really only conventient for perl, that moving
away from the simple TAP format we currently have to something with more markup is going to make life very difficult for TAP producers written in
other languages.

We're defining a subset of YAML (YAMLish) that should be simple to implement in many languages. YAMLish was based initially on the YAML subset that YAML::Tiny supports. Since then I've made it able to handle arbitrary strings as hash keys (YAML::Tiny needs hash keys like \w\S+).

so, is that argument being dismissed as irrelevant now?  or was it
forgotten?  or was it carefully analyzed and determined that, despite
this hardship, YAML represents the best alternative given the problem set.

Getting people from other languages interested in TAP is absolutely on the agenda. That's why we have testanything.org - it's all about TAP without any specific language bias.

YAMLish is amenable to lightweight implementations. The current YAMLish writer is 124 lines of nicely formatted Perl and the parser is 258 lines. There's no trick Perl in there and it should translate pretty easily to other languages.

When I get a moment I'll probably produce PHP and JS implementations and of course anyone else is welcome to implement it in their language of choice.

--
Andy Armstrong, hexten.net

Reply via email to