[pytest-dev] junitxml incremental output writing

Floris Bruynooghe flub at devork.be
Sun Apr 5 09:12:52 EDT 2020


Hello all,

One of the most common things users of pytest-timeout struggle with is
that they lose Junit XML reporting when a timeout occurs.  This never
bothered me, it was by design, but that doesn't stop users from being
bothered.

Which made me wonder, does anyone know if there's a reason that the
Junit XML reporting can't write it's report incrementally as each test
executed?  Not sure that would work well with xdist though.

An additional thing or alternative would be if there's a hook that we
could use from plugins to say "finish reporting now".  So
e.g. pytest-timeout could report a failure for the test which timed out,
call this hook and only then terminate the process.


I'm only bouncing around ill-thought through ideas around this to see
what other people think.

Cheers,
Floris


More information about the pytest-dev mailing list