macro_rules! get_stdout_for {
($test:expr) => { ... };
}
Expand description
ยงcatches what the expression would write to the stdout
This macro takes an expression, executes it, and catches what it would write to the stdout. The buffer of the stdout will then be returned for further use.
This is especially useful when testing loggers or other frontend CLI functions.