[racket] Thoughts on Overeasy
Some quick notes:
Generally good. Certainly cuts down on some of the crap that Rackunit
/ Schemeunit requires while being more comprehensible than eli-tester.
---
I think the keyword argument method is a mistake. It seems you'd have
to do a lot of checking in the test macro to make sure the user
doesn't specify non-sensical parameters. E.g. if I specify #:exn and
#:val what happens? How about,
(test value-expr match-expr)
value-expr is the expression under test, as currently.
The test macro grabs whatever values value-expr produces, along with
the output to current-output and current-error, and any exceptions and
passes these values to
match-expr, which is a predicate that produces a boolean value given
the above information
There can be a shorthand for common cases. If match-expr evaluates to
a literal then just check value-expr's value is equal? to that
literal. For more existing cases one can write a little DSL based on
match.
---
Since test must be a macro, it should capture location and report that
when a test fails.
---
"No special forms for setup and tear-down are required, nor are they
provided." I believe a test library should provide these conveniences
around dynamic-wind.
HTH,
N.