[PATCH v2 1/2] tests: Save a log of wmediumd

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Signed-off-by: Masashi Honma <masashi.honma@xxxxxxxxx>
---
 tests/hwsim/run-tests.py     | 2 ++
 tests/hwsim/test_wmediumd.py | 6 +++---
 2 files changed, 5 insertions(+), 3 deletions(-)

diff --git a/tests/hwsim/run-tests.py b/tests/hwsim/run-tests.py
index 6f62dea..80981ba 100755
--- a/tests/hwsim/run-tests.py
+++ b/tests/hwsim/run-tests.py
@@ -516,6 +516,8 @@ def main():
                 rename_log(args.logdir, 'fst-wpa_supplicant', name, None)
             if os.path.exists(os.path.join(args.logdir, 'fst-hostapd')):
                 rename_log(args.logdir, 'fst-hostapd', name, None)
+            if os.path.exists(os.path.join(args.logdir, 'wmediumd.log')):
+                rename_log(args.logdir, 'wmediumd.log', name, None)
 
         end = datetime.now()
         diff = end - start
diff --git a/tests/hwsim/test_wmediumd.py b/tests/hwsim/test_wmediumd.py
index 3319673..42cb9c9 100644
--- a/tests/hwsim/test_wmediumd.py
+++ b/tests/hwsim/test_wmediumd.py
@@ -18,7 +18,7 @@ ifaces :
 };
 """
 
-def test_wmediumd_simple(dev, apdev):
+def test_wmediumd_simple(dev, apdev, params):
     """test a simple wmediumd configuration"""
     fd, fn = tempfile.mkstemp()
     try:
@@ -26,8 +26,8 @@ def test_wmediumd_simple(dev, apdev):
         f.write(CFG % (apdev[0]['bssid'], dev[0].own_addr()))
         f.close()
         try:
-            p = subprocess.Popen(['wmediumd', '-c', fn],
-                                 stdout=open('/dev/null', 'a'),
+            p = subprocess.Popen(['wmediumd', '-l', '6', '-c', fn],
+                                 stdout=open(os.path.abspath(os.path.join(params['logdir'], 'wmediumd.log')), 'a'),
                                  stderr=subprocess.STDOUT)
         except OSError, e:
             if e.errno == errno.ENOENT:
-- 
2.7.4


_______________________________________________
Hostap mailing list
Hostap@xxxxxxxxxxxxxxxxxxx
http://lists.infradead.org/mailman/listinfo/hostap



[Index of Archives]     [Linux Wireless]     [Linux Kernel]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Device Mapper]

  Powered by Linux