From ec2a995c36f0757e1f5c695a80d89f41d2fa03bb Mon Sep 17 00:00:00 2001 From: Aleksandr Dovydenkov Date: Fri, 5 Dec 2025 16:12:50 +0300 Subject: [PATCH] tests/fprintd: fix tests to use new GLib version Tests, that uses GLib.GError with bytes instead of strings type for message were broken when implementation was changed in GLib update. Should use GError calls with decode call to fix it. Signed-off-by: Aleksandr Dovydenkov --- tests/fprintd.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/tests/fprintd.py b/tests/fprintd.py index a1fef1c..8d8fe6e 100644 --- a/tests/fprintd.py +++ b/tests/fprintd.py @@ -592,10 +592,10 @@ class FPrintdTest(dbusmock.DBusTestCase): proc = self.gdbus_device_method_call_process(method, args) proc.wait(timeout=5) if proc.returncode != 0: - raise GLib.GError(proc.stdout.read()) + raise GLib.GError(proc.stdout.read().decode()) return proc.stdout.read() except subprocess.TimeoutExpired as e: - raise GLib.GError(e.output) + raise GLib.GError(e.output.decode()) class FPrintdVirtualImageDeviceBaseTests(FPrintdTest): @@ -2990,7 +2990,7 @@ class FPrindConcurrentPolkitRequestsTest(FPrintdVirtualStorageDeviceBaseTest): gdbus.wait() with self.assertFprintError('AlreadyInUse'): - raise GLib.GError(gdbus.stdout.read()) + raise GLib.GError(gdbus.stdout.read().decode()) self.device.Release() @@ -3032,7 +3032,7 @@ class FPrindConcurrentPolkitRequestsTest(FPrintdVirtualStorageDeviceBaseTest): gdbus.wait() with self.assertFprintError('AlreadyInUse'): - raise GLib.GError(gdbus.stdout.read()) + raise GLib.GError(gdbus.stdout.read().decode()) self.device.Release()