about summary refs log tree commit diff
path: root/debian/tests/control
diff options
context:
space:
mode:
authorRobie Basak <robie.basak@canonical.com>2018-11-27 18:10:33 +0000
committerRobie Basak <robie.basak@canonical.com>2018-11-29 12:39:13 +0000
commitef394e06cf4b7f2e1ab3132fc4a2e21ada7f52cd (patch)
tree14b3679dfb386f204bc9d7c8f1ee8e44dc5cb0b8 /debian/tests/control
parent011044ef70eeacfee438a979f1f41870ff17a74c (diff)
Make dep8 nm test directly invokable
By renaming the test to nm.py, it can be called directly with:

    python3 -m unittest nm

To make this work, we also need to move required test setup and teardown
code to setUpModule() and tearDownModule() accordingly, and move other
"script" code into the __name__ == '__main__' idiom.

This then allows easier debugging of failing tests by calling unittest
to run a specific test using the usual method. For example:

    sudo python3 -m unittest nm.ColdplugWifi.test_open_b_ip6_raonly_no_pe
Diffstat (limited to 'debian/tests/control')
-rw-r--r--debian/tests/control2
1 files changed, 1 insertions, 1 deletions
diff --git a/debian/tests/control b/debian/tests/control
index 14ebb2f5..a8f4d148 100644
--- a/debian/tests/control
+++ b/debian/tests/control
@@ -2,7 +2,7 @@ Tests: wpa-dhclient
 Depends: python3, hostapd, dnsmasq-base, wpasupplicant, isc-dhcp-client, iw
 Restrictions: needs-root allow-stderr isolation-machine
 
-Tests: nm
+Tests: nm.py
 Depends: python3, dnsmasq-base, isc-dhcp-client, gir1.2-networkmanager-1.0, network-manager, hostapd, iw, python3-dbusmock
 Restrictions: needs-root isolation-machine