mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager.git
synced 2026-02-04 04:50:30 +01:00
test-client: pass LIBNM_CLIENT_DEBUG to nmcli
For debugging libnm, LIBNM_CLIENT_DEBUG can be very useful.
As the tests compare stdout/stderr from nmcli with expected output, just
enabling it will break the tests. However, in combination with
LIBNM_CLIENT_DEBUG_FILE this can be very useful.
Preserve and pass on the environment variables, if set.
(cherry picked from commit 1630009234)
This commit is contained in:
parent
6adca24ee1
commit
1a9892620e
1 changed files with 6 additions and 1 deletions
|
|
@ -996,7 +996,12 @@ class TestNmcli(unittest.TestCase):
|
|||
self.fail("invalid language %s" % (lang))
|
||||
|
||||
env = {}
|
||||
for k in ["LD_LIBRARY_PATH", "DBUS_SESSION_BUS_ADDRESS"]:
|
||||
for k in [
|
||||
"LD_LIBRARY_PATH",
|
||||
"DBUS_SESSION_BUS_ADDRESS",
|
||||
"LIBNM_CLIENT_DEBUG",
|
||||
"LIBNM_CLIENT_DEBUG_FILE",
|
||||
]:
|
||||
val = os.environ.get(k, None)
|
||||
if val is not None:
|
||||
env[k] = val
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue