From b18f84353268d3ecbf5121fcc0b855ed2d16caa7 Mon Sep 17 00:00:00 2001 From: James Prestwood Date: Thu, 10 Dec 2020 09:45:20 -0800 Subject: [PATCH] auto-t: add storage dir to IWD() constructor Add support for setting a custom storage directory. --- autotests/util/iwd.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/autotests/util/iwd.py b/autotests/util/iwd.py index bb4ecefa..844bb0db 100755 --- a/autotests/util/iwd.py +++ b/autotests/util/iwd.py @@ -943,7 +943,8 @@ class IWD(AsyncOpAbstract): _default_instance = None psk_agent = None - def __init__(self, start_iwd_daemon = False, iwd_config_dir = '/tmp', namespace=ctx): + def __init__(self, start_iwd_daemon = False, iwd_config_dir = '/tmp', + iwd_storage_dir = '/tmp/iwd', namespace=ctx): self.namespace = namespace self._bus = namespace.get_bus() @@ -951,7 +952,8 @@ class IWD(AsyncOpAbstract): if self.namespace.is_process_running('iwd'): raise Exception("IWD requested to start but is already running") - self._iwd_proc = self.namespace.start_iwd(iwd_config_dir) + self._iwd_proc = self.namespace.start_iwd(iwd_config_dir, + iwd_storage_dir) tries = 0 while not self._bus.name_has_owner(IWD_SERVICE):