test: add test that ensures return value of chroot.run()
Small followup for https://github.com/osbuild/osbuild/pull/1854 which added the return value to `util.Chroot.run`. This commit now adds a (super trivial) test for this.
This commit is contained in:
parent
6953ea89b4
commit
ed95178b80
1 changed files with 2 additions and 1 deletions
|
|
@ -22,7 +22,8 @@ class RunReturn:
|
|||
def test_chroot_context(mocked_run, tmp_path):
|
||||
|
||||
with Chroot(os.fspath(tmp_path)) as chroot:
|
||||
chroot.run(["/bin/true"], check=True)
|
||||
ret = chroot.run(["/bin/true"], check=True)
|
||||
assert isinstance(ret, RunReturn)
|
||||
chroot.run(["/bin/false"], check=False)
|
||||
|
||||
assert mocked_run.call_args_list == [
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue