Skip to content

Commit

Permalink
tests: Run tmt report on failure
Browse files Browse the repository at this point in the history
It's annoying to have to go dig through the logs when something
fails. We do have the tmt logs in CI, but again, more clicks.

Signed-off-by: Colin Walters <[email protected]>
  • Loading branch information
cgwalters committed Jul 25, 2024
1 parent a557143 commit ee37c64
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion xtask/src/xtask.rs
Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,11 @@ fn test_tmt(sh: &Shell) -> Result<()> {
cmd!(sh, "cargo run -p tests-integration run-vm prepare-tmt").run()?;
// cc https://pagure.io/testcloud/pull-request/174
cmd!(sh, "rm -vf /var/tmp/tmt/testcloud/images/disk.qcow2").run()?;
cmd!(sh, "tmt run plans -n integration-run").run()?;
if let Err(e) = cmd!(sh, "tmt run plans -n integration-run").run() {
// tmt annoyingly does not output errors by default
let _ = cmd!(sh, "tmt run -l report -vvv").run();
return Err(e.into());
}
Ok(())
}

Expand Down

0 comments on commit ee37c64

Please sign in to comment.