Skip to content

Commit

Permalink
Apply formatting changes from black 23.7.0
Browse files Browse the repository at this point in the history
Signed-off-by: Bryan Gurney <[email protected]>
  • Loading branch information
bgurney-rh committed Nov 27, 2023
1 parent 172308d commit 19afbdb
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 4 deletions.
2 changes: 1 addition & 1 deletion tests/client-dbus/tests/udev/_loopback.py
Original file line number Diff line number Diff line change
Expand Up @@ -207,7 +207,7 @@ def destroy_devices(self):
Detach loopbacks and remove backing files
:return:
"""
for (device, backing_file) in self.devices.values():
for device, backing_file in self.devices.values():
if device is not None:
subprocess.check_call([_LOSETUP_BIN, "-d", device])
os.remove(backing_file)
Expand Down
4 changes: 2 additions & 2 deletions tests/client-dbus/tests/udev/_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -326,7 +326,7 @@ def __enter__(self):
:raises RuntimeError: if setting a key in the keyring through stratisd
fails
"""
for (key_desc, key_data) in self._key_descs:
for key_desc, key_data in self._key_descs:
with NamedTemporaryFile(mode="w") as temp_file:
temp_file.write(key_data)
temp_file.flush()
Expand All @@ -349,7 +349,7 @@ def __enter__(self):

def __exit__(self, exception_type, exception_value, traceback):
try:
for (key_desc, _) in reversed(self._key_descs):
for key_desc, _ in reversed(self._key_descs):
(_, return_code, message) = Manager.Methods.UnsetKey(
get_object(TOP_OBJECT), {"key_desc": key_desc}
)
Expand Down
6 changes: 5 additions & 1 deletion tests/client-dbus/tests/udev/test_predict.py
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,11 @@ def _possibly_add_filesystems(pool_object_path, *, fs_specs=None):
if not real:
raise RuntimeError("Failed to get pool usage before creating filesystems.")

(_, return_code, message,) = Pool.Methods.CreateFilesystems(
(
_,
return_code,
message,
) = Pool.Methods.CreateFilesystems(
pool_proxy,
{"specs": map(lambda x: (x[0], (True, str(x[1].magnitude))), fs_specs)},
)
Expand Down

0 comments on commit 19afbdb

Please sign in to comment.