Right now the only communication channel we have between the testrunner and Rust tests, during execution, is the process exit code. We'd like to have a richer protocol but the Rust test harness is kind of limited so we need to be careful about it. Some ideas for things to communicate:
- test flakiness
- test retries
- test timeouts
Some ideas for the protocol itself:
- Use lines to stdout (or stderr) that begin with
nextest: (similar to cargo: lines in build scripts)
- Pass in a random string through the environment and ensure that lines begin with that to avoid confusing random test output with nextest control lines.
- Publish a crate which can be used to output these lines, either as function calls or as a proc macro.