[prev in list] [next in list] [prev in thread] [next in thread] 

List:       lnst-developers
Subject:    [lnst] TestIperf: bind option not specified bug
From:       Jiří Pírko <jirka () fedoraproject ! org>
Date:       2013-02-08 12:12:35
Message-ID: 20130208121235.472812426 () fedorahosted ! org
[Download RAW message or body]

commit 2d7765cad0d30e83ffca61d309871da52dbfe091
Author: Ondrej Lichtner <olichtne@redhat.com>
Date:   Fri Feb 8 11:09:49 2013 +0100

    TestIperf: bind option not specified bug
    
    When the module is run in the 'server' role and the option 'bind' is not
    specified, the constructed command contains 'None' instead, creating an
    invalid command.
    
    This commit fixes that.
    
    Signed-off-by: Ondrej Lichtner <olichtne@redhat.com>

 test_modules/TestIperf.py |    5 ++++-
 1 files changed, 4 insertions(+), 1 deletions(-)
---
diff --git a/test_modules/TestIperf.py b/test_modules/TestIperf.py
index 0a9b047..462c48c 100644
--- a/test_modules/TestIperf.py
+++ b/test_modules/TestIperf.py
@@ -26,7 +26,10 @@ class TestIperf(TestGeneric):
             cmd = "iperf --%s %s -t %s %s" % (role, iperf_server, self.duration, iperf_options)
         elif role == "server":
             bind = self.get_opt("bind", opt_type="addr")
-            cmd = "iperf --%s -B %s %s" % (role, bind, iperf_options)
+            if bind != None:
+                cmd = "iperf --%s -B %s %s" % (role, bind, iperf_options)
+            else:
+                cmd = "iperf --%s %s" % (role, iperf_options)
 
         return cmd
 
_______________________________________________
LNST-developers mailing list
LNST-developers@lists.fedorahosted.org
https://lists.fedorahosted.org/mailman/listinfo/lnst-developers

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic