From 3b5e4d1e3cf7b23fcb0bed12763666aa564acaff Mon Sep 17 00:00:00 2001 From: Tim Peters Date: Thu, 19 Jul 2001 19:02:12 +0000 Subject: Cosmetic: break the long lines in test_ntpath.py, and get rid of its expected-output file. --- Lib/test/output/test_ntpath | 2 -- Lib/test/test_ntpath.py | 21 ++++++++++++++------- 2 files changed, 14 insertions(+), 9 deletions(-) delete mode 100644 Lib/test/output/test_ntpath diff --git a/Lib/test/output/test_ntpath b/Lib/test/output/test_ntpath deleted file mode 100644 index 92caf34..0000000 --- a/Lib/test/output/test_ntpath +++ /dev/null @@ -1,2 +0,0 @@ -test_ntpath -No errors. Thank your lucky stars. diff --git a/Lib/test/test_ntpath.py b/Lib/test/test_ntpath.py index 7867fd9..b0c1b7c 100644 --- a/Lib/test/test_ntpath.py +++ b/Lib/test/test_ntpath.py @@ -1,4 +1,5 @@ import ntpath +from test_support import verbose import os errors = 0 @@ -15,16 +16,22 @@ def tester(fn, wantResult): global errors errors = errors + 1 -tester('ntpath.splitdrive("c:\\foo\\bar")', ('c:', '\\foo\\bar')) -tester('ntpath.splitunc("\\\\conky\\mountpoint\\foo\\bar")', ('\\\\conky\\mountpoint', '\\foo\\bar')) -tester('ntpath.splitdrive("c:/foo/bar")', ('c:', '/foo/bar')) -tester('ntpath.splitunc("//conky/mountpoint/foo/bar")', ('//conky/mountpoint', '/foo/bar')) +tester('ntpath.splitdrive("c:\\foo\\bar")', + ('c:', '\\foo\\bar')) +tester('ntpath.splitunc("\\\\conky\\mountpoint\\foo\\bar")', + ('\\\\conky\\mountpoint', '\\foo\\bar')) +tester('ntpath.splitdrive("c:/foo/bar")', + ('c:', '/foo/bar')) +tester('ntpath.splitunc("//conky/mountpoint/foo/bar")', + ('//conky/mountpoint', '/foo/bar')) tester('ntpath.split("c:\\foo\\bar")', ('c:\\foo', 'bar')) -tester('ntpath.split("\\\\conky\\mountpoint\\foo\\bar")', ('\\\\conky\\mountpoint\\foo', 'bar')) +tester('ntpath.split("\\\\conky\\mountpoint\\foo\\bar")', + ('\\\\conky\\mountpoint\\foo', 'bar')) tester('ntpath.split("c:\\")', ('c:\\', '')) -tester('ntpath.split("\\\\conky\\mountpoint\\")', ('\\\\conky\\mountpoint', '')) +tester('ntpath.split("\\\\conky\\mountpoint\\")', + ('\\\\conky\\mountpoint', '')) tester('ntpath.split("c:/")', ('c:/', '')) tester('ntpath.split("//conky/mountpoint/")', ('//conky/mountpoint', '')) @@ -45,5 +52,5 @@ tester('ntpath.commonprefix(["/home/swen/spam", "/home/swen/spam"])', if errors: print str(errors) + " errors." -else: +elif verbose: print "No errors. Thank your lucky stars." -- cgit v0.12