From c79f583e0c79d95b577c894bdba8975c23110bf3 Mon Sep 17 00:00:00 2001 From: Andrew Zaborowski Date: Sat, 28 Aug 2021 05:10:54 +0200 Subject: [PATCH] test-runner: Fix verbose check for processes in namespaces Check whether verbose output is enabled for process name arg[0] before prepending the "ip netns exec" part to arg since arg[0] is going to be "ip" after that. --- tools/test-runner | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tools/test-runner b/tools/test-runner index 513af2ab..fc57cd81 100755 --- a/tools/test-runner +++ b/tools/test-runner @@ -176,12 +176,12 @@ class Process(subprocess.Popen): global config self.ctx = config.ctx - if namespace: - args = ['ip', 'netns', 'exec', namespace] + args - if self.ctx.is_verbose(args[0], log=False): self.verbose = True + if namespace: + args = ['ip', 'netns', 'exec', namespace] + args + if outfile: self._append_outfile(outfile)