mirror of
https://github.com/virt-manager/virt-manager.git
synced 2025-02-03 13:47:18 +03:00
urlfetcher: Write test file as binary content
Triggers an test_ui error otherwise: TypeError: write() argument must be str, not bytes
This commit is contained in:
parent
d82022bd2c
commit
374a3779c4
@ -155,7 +155,7 @@ class _URLFetcher(object):
|
||||
# pylint: disable=redefined-variable-type
|
||||
if "VIRTINST_TEST_SUITE" in os.environ:
|
||||
fn = os.path.join("/tmp", prefix)
|
||||
fileobj = open(fn, "w")
|
||||
fileobj = open(fn, "wb")
|
||||
else:
|
||||
fileobj = tempfile.NamedTemporaryFile(
|
||||
dir=self.scratchdir, prefix=prefix, delete=False)
|
||||
|
Loading…
x
Reference in New Issue
Block a user