Join Nostr
2026-04-18 09:16:36 UTC

Screwtapello on Nostr: Sometimes, when I write a little tool, I am responsible enough to write some tests. ...

Sometimes, when I write a little tool, I am responsible enough to write some tests. When it's a Python tool, I can use Python's excellent built-in test harness (`python -m unittest`), but when I'm using some other language — or worse, a combination of languages — it would be nice to have a similar tool available.

I've discovered Perl's `prove` command - it looks for executable scripts matching `t/*.t`, it runs them (possibly in parallel), interprets their output according to a very straight-forward plain-text protocol ( https://testanything.org/ ), and shows a summary of the results. Very nice!

Unfortunately, when a test fails, it doesn't actually tell you *which* test failed. You can run `prove -f` which runs the tests again and prints the name of failing tests, but *only* the name. If they printed out some helpful diagnostics or logging, it's lost. You can also add verbose mode with `prove -f -v` to print all the diagnostics tests produce - but it shows *all* the diagnostics, even the ones from passing tests, not just the failed tests.

This seems... suboptimal.

#perl #tap