summaryrefslogtreecommitdiffhomepage
path: root/test.py
diff options
context:
space:
mode:
authorRobey Pointer <robey@ralph.lag.net>2005-12-02 20:39:19 -0800
committerRobey Pointer <robey@ralph.lag.net>2005-12-02 20:39:19 -0800
commit9b5d80869c664228b6dd9e8971c269854879f71f (patch)
tree8487a048104e999eb8b0d1e1772646409b1353eb /test.py
parenta6b48752864d0f9f90de117b66d7b669857d2aad (diff)
[project @ robey@ralph.lag.net-20051203043919-0a8c4665d04853fc]
turn down output for unit tests by default, but add --verbose option to manually crank them back up
Diffstat (limited to 'test.py')
-rwxr-xr-xtest.py7
1 files changed, 6 insertions, 1 deletions
diff --git a/test.py b/test.py
index 97188a4e..e75e8efd 100755
--- a/test.py
+++ b/test.py
@@ -42,6 +42,8 @@ default_keyfile = os.path.join(os.environ.get('HOME', '/'), '.ssh/id_rsa')
default_passwd = None
parser = OptionParser('usage: %prog [options]')
+parser.add_option('--verbose', action='store_true', dest='verbose', default=False,
+ help='verbose display (one line per test)')
parser.add_option('--no-pkey', action='store_false', dest='use_pkey', default=True,
help='skip RSA/DSS private key tests (which can take a while)')
parser.add_option('--no-transport', action='store_false', dest='use_transport', default=True,
@@ -93,4 +95,7 @@ if options.use_transport:
suite.addTest(unittest.makeSuite(TransportTest))
if options.use_sftp:
suite.addTest(unittest.makeSuite(SFTPTest))
-unittest.TextTestRunner(verbosity=2).run(suite)
+verbosity = 1
+if options.verbose:
+ verbosity = 2
+unittest.TextTestRunner(verbosity=verbosity).run(suite)