diff --git a/tests/client-dbus/tests/udev/test_predict.py b/tests/client-dbus/tests/udev/test_predict.py index be8227447a3..527d4149591 100644 --- a/tests/client-dbus/tests/udev/test_predict.py +++ b/tests/client-dbus/tests/udev/test_predict.py @@ -105,7 +105,7 @@ def _possibly_add_filesystems(pool_object_path, *, fs_specs=None): :param str pool_object_path: the D-Bus object path :param fs_specs: the filesystem specs - :type fs_specs: list of str * Range or NoneType + :type fs_specs: list of str * (Range or NoneType) * (Range or NoneType) :returns: the change in size of pool's TotalPhysicalUsed value :rtype: Range @@ -123,7 +123,16 @@ def _possibly_add_filesystems(pool_object_path, *, fs_specs=None): message, ) = Pool.Methods.CreateFilesystems( pool_proxy, - {"specs": map(lambda x: (x[0], (True, str(x[1].magnitude))), fs_specs)}, + { + "specs": map( + lambda x: ( + x[0], + (False, "") if x[1] is None else (True, str(x[1].magnitude)), + (False, "") if x[2] is None else (True, str(x[2].magnitude)), + ), + fs_specs, + ) + }, ) if return_code != 0: @@ -302,7 +311,7 @@ def test_prediction_filesystems(self): pool_name = random_string(5) create_pool(pool_name, devnodes) self.wait_for_pools(1) - self._test_prediction(pool_name, fs_specs=[("fs1", Range(1, TiB))]) + self._test_prediction(pool_name, fs_specs=[("fs1", Range(1, TiB), None)]) def test_prediction_no_overprov(self): """ @@ -317,5 +326,5 @@ def test_prediction_no_overprov(self): create_pool(pool_name, devnodes, overprovision=False) self.wait_for_pools(1) self._test_prediction( - pool_name, fs_specs=[("fs1", Range(2, GiB))], overprovision=False + pool_name, fs_specs=[("fs1", Range(2, GiB), None)], overprovision=False )