diff options
author | Robey Pointer <robey@lag.net> | 2004-12-19 19:56:48 +0000 |
---|---|---|
committer | Robey Pointer <robey@lag.net> | 2004-12-19 19:56:48 +0000 |
commit | 811f2bf30f011f911fa72b29e7a566e6f6c2acab (patch) | |
tree | 86477e9d7624fb5408bdce4b4aa6adf4cc1b1f64 /test.py | |
parent | 34f9df15361b4e069e172679ccc1e478a240cd91 (diff) |
[project @ Arch-1:robey@lag.net--2003-public%secsh--dev--1.0--patch-136]
loopback sftp test
add ability to turn off more tests, and a secret (for now) -X option to do
the sftp tests via loopback socket. added another symlink sftp test to see
what happens with absolute symlinks.
Diffstat (limited to 'test.py')
-rwxr-xr-x | test.py | 14 |
1 files changed, 12 insertions, 2 deletions
@@ -57,6 +57,11 @@ parser.add_option('-P', '--sftp-passwd', dest='password', type='string', default help='(optional) password to unlock the private key for sftp tests') 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, + help='skip transport tests (which can take a while)') +parser.add_option('--no-big-file', action='store_false', dest='use_big_file', default=True, + help='skip big file SFTP tests, which are slow as molasses') +parser.add_option('-X', action='store_true', dest='use_loopback_sftp', default=False) options, args = parser.parse_args() if len(args) > 0: @@ -64,6 +69,10 @@ if len(args) > 0: if options.use_sftp: SFTPTest.init(options.hostname, options.username, options.keyfile, options.password) +if options.use_loopback_sftp: + SFTPTest.init_loopback() +if not options.use_big_file: + SFTPTest.set_big_file_test(False) # setup logging paramiko.util.log_to_file('test.log') @@ -74,7 +83,8 @@ suite.addTest(unittest.makeSuite(BufferedFileTest)) if options.use_pkey: suite.addTest(unittest.makeSuite(KeyTest)) suite.addTest(unittest.makeSuite(KexTest)) -suite.addTest(unittest.makeSuite(TransportTest)) -if options.use_sftp: +if options.use_transport: + suite.addTest(unittest.makeSuite(TransportTest)) +if options.use_sftp or options.use_loopback_sftp: suite.addTest(unittest.makeSuite(SFTPTest)) unittest.TextTestRunner(verbosity=2).run(suite) |