TestAnything / testanything.github.io

Test anything protocol website
testanything.org
Other
71 stars 65 forks source link

Add 'greatest' to the C section #160

Open ssokolow opened 3 years ago

ssokolow commented 3 years ago

The greatest single-file C test framework comes with an awk script (mentioned in the README) that will convert its verbose output into TAP version 13.

(My understanding is that the TAP support is implemented as an external filter because the author is trying to keep greatest.h small.)

If you're including cmocka in your list, I'd highly recommend also including greatest.

cmocka is a complex framework that's, at best, difficult to set up for unsupported compilers. When I reviewed a bunch of test frameworks with the intent to use them for DOS hobby projects using Open Watcom C/C++, greatest was the one I recommended as the best blend of compatibility (just needs C89, no dynamic allocation, builds and runs for a real-mode DOS target), ease of use (single file), and features.

(I've included a screenshot in my review of it, and a code sample which didn't generate it... but only because I wanted the screenshot to show more than one or two tests and I didn't want the code example to be long and repetitive.)

The key takeaway from my review was "For something that works with Open Watcom C/C++ v1.9, the experience is surprisingly reminiscent of Python’s standard library unittest module."

mblayman commented 3 years ago

The content on the TAP website is entirely driven by the community. If you'd like to submit a PR to the TAP producers page, I'd be happy to accept it as long as it follows the format of that page.

ssokolow commented 3 years ago

I'll see if I can find time to do that in the next few days.