Combine if and assert statement

This commit is contained in:
Andrew Murray 2023-10-19 20:34:28 +11:00
parent 8b71f3d3c1
commit e760b02bfa

View File

@ -26,8 +26,7 @@ def open_with_magick(magick, tmp_path, f):
rc = subprocess.call( rc = subprocess.call(
magick + [f, outfile], stdout=subprocess.DEVNULL, stderr=subprocess.STDOUT magick + [f, outfile], stdout=subprocess.DEVNULL, stderr=subprocess.STDOUT
) )
if rc: assert not rc
assert False
return Image.open(outfile) return Image.open(outfile)