From aa729110c08853dea68a3f484cf576b9b2bae99b Mon Sep 17 00:00:00 2001 From: Henning Glawe <glaweh@debian.org> Date: Tue, 18 Mar 2025 18:12:42 +0100 Subject: [PATCH] reformat with black --- src/mpsd_hpc_tools/quota.py | 2 +- tests/test_quota.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/mpsd_hpc_tools/quota.py b/src/mpsd_hpc_tools/quota.py index ae370af..d8faed8 100644 --- a/src/mpsd_hpc_tools/quota.py +++ b/src/mpsd_hpc_tools/quota.py @@ -87,7 +87,7 @@ def df_mountpoint(path: pathlib.Path) -> Tuple[int, int, int]: return None, None, None for line in output.splitlines(): df_fields = line.split() - if (df_fields[0] == "Filesystem"): + if df_fields[0] == "Filesystem": continue (size, used, avail) = [int(df_field) for df_field in df_fields[1:4]] return size, used, avail diff --git a/tests/test_quota.py b/tests/test_quota.py index 91013e6..3513ed9 100644 --- a/tests/test_quota.py +++ b/tests/test_quota.py @@ -54,7 +54,7 @@ def test_df_ceph(mocker): def test_df_mountpoint(mocker): mock = mocker.patch( "subprocess.check_output", - return_value="Filesystem 1B-blocks Used Available Use% Mounted on\nsomedev 1000 500 500 1% /home/glawe\n".encode() + return_value="Filesystem 1B-blocks Used Available Use% Mounted on\nsomedev 1000 500 500 1% /home/glawe\n".encode(), ) size, used, avail = quota.df_mountpoint("/home/MOCK") assert isinstance(size, int) -- GitLab