mirror of
https://github.com/ostreedev/ostree.git
synced 2025-08-29 01:49:24 +03:00
tests/transactionality: Port a bit to xshell
This will give us more useful error messages which should help debug a flake.
This commit is contained in:
@ -459,17 +459,14 @@ fn impl_transaction_test<M: AsRef<str>>(
|
||||
// Reset the target ref to booted, and perform a cleanup
|
||||
// to ensure we're re-downloading objects each time
|
||||
let testref = TESTREF;
|
||||
bash!(
|
||||
"
|
||||
systemctl stop rpm-ostreed
|
||||
systemctl stop ostree-finalize-staged
|
||||
systemctl stop ostree-finalize-staged-hold
|
||||
ostree reset testrepo:${testref} ${booted_commit}
|
||||
rpm-ostree cleanup -pbrm
|
||||
",
|
||||
testref,
|
||||
booted_commit
|
||||
)
|
||||
(|| -> Result<()> {
|
||||
cmd!(sh, "systemctl stop rpm-ostreed").run()?;
|
||||
cmd!(sh, "systemctl stop ostree-finalize-staged").run()?;
|
||||
cmd!(sh, "systemctl stop ostree-finalize-staged-hold").run()?;
|
||||
cmd!(sh, "ostree reset testrepo:{testref} {booted_commit}").run()?;
|
||||
cmd!(sh, "rpm-ostree cleanup -pbrm").run()?;
|
||||
Ok(())
|
||||
})()
|
||||
.with_context(|| {
|
||||
format!(
|
||||
"Failed pre-upgrade cleanup (prev strategy: {})",
|
||||
|
Reference in New Issue
Block a user