diff --git a/unit-tests/dds/librs.py b/unit-tests/dds/librs.py index 9a99e828f5..3c80cefc59 100644 --- a/unit-tests/dds/librs.py +++ b/unit-tests/dds/librs.py @@ -39,7 +39,11 @@ def wait_for_devices( context, mask=product_line.any, n=1, timeout=3, throw=None timer = _Timer( timeout ) devices = context.query_devices( mask ) if len(devices) >= n: - if not exact or len(devices) == n: + if not exact: + return devices + if len(devices) == n: + if n == 1: + return devices[0] return devices # context.set_devices_changed_callback( _device_change_callback )