You can use foldts-test-suite 
(part of the rackunit package) to write your own test runner which collects 
and reports on the tests according to your needs.  This will only work for 
the rackunit tests which are organized in test suites and test cases, not 
with simple `check-*` written inside test modules.

I used it myself to write a test runner which runs rackunit tests and 
outputs the results as JUnit XML test files.  This is a widely supported 
test result format that can be imported into test reporting applications.


On Saturday, May 23, 2020 at 7:47:47 AM UTC+8, Shriram Krishnamurthi wrote:
> I'm trying to understand the design of the logging portion of rackunit:
>    1. The "log" seems to only be a *count*, not the actual rackunit 
>    output (as the term "log" would suggest). Since I want to show a summary 
> of 
>    tests — including output — on a different medium, after the test suite has 
>    run, it looks like I need to essentially create my own logging support? 
>    (Perhaps the "check-info stack" is useful here, but I don't think so.)
>    2. Why do the check-… procedures not return any value? It would seem 
>    natural for them to return, say, false in case of passing and a failure 
>    information structure in case of failing (or a structure in both cases). 
>    But they seem to only return void, so I'm not entirely sure how else to 
>    extract the information for the log without rewriting the check's.
>    3. As an aside, I'm not entirely sure what `test-log!` is there for. 
>    Presumably it's to record in the log "tests" run by operations that are 
> not 
>    part of rackunit? I'm curious how people have used it.
> TL;DR: If I want to record what happened on all the checks for 
> post-execution processing, do I need to (a) create my own log and, to do 
> so, (b) rewrite all the checking predicates to provide the information that 
> the detailed log needs?
> Thanks,
> Shriram

You received this message because you are subscribed to the Google Groups 
"Racket Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
To view this discussion on the web visit

Reply via email to