Alternate libtest output format

It depends on if the current libtest has access to this information. Wouldn't a test name be enough?

Well, assuming the stdout/stderr is textual, it can be just added as another field to the JSON output. Non-printable characters can be escaped, I guess.