summaryrefslogtreecommitdiff
path: root/src/distutils2/command
diff options
context:
space:
mode:
authorKonrad Delong <konryd@gmail.com>2010-08-12 20:49:01 +0200
committerKonrad Delong <konryd@gmail.com>2010-08-12 20:49:01 +0200
commit4f38dcb142b5856ad97ac882c5f6b48cdc8206a5 (patch)
tree7ba44c00b1ebf6ed07274b3828d83e224135c254 /src/distutils2/command
parente466cd1e80e7a13c5ae3a34d022bcefbe63858b5 (diff)
downloaddisutils2-4f38dcb142b5856ad97ac882c5f6b48cdc8206a5.tar.gz
made the test_test pass again + added test boilerplate
Diffstat (limited to 'src/distutils2/command')
-rw-r--r--src/distutils2/command/test.py7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/distutils2/command/test.py b/src/distutils2/command/test.py
index bdaf1d6..10c82b6 100644
--- a/src/distutils2/command/test.py
+++ b/src/distutils2/command/test.py
@@ -38,9 +38,10 @@ class test(Command):
args = {"module": self.test_suite,
"argv": sys.argv[:1]
}
- loader_instance = resolve_name(self.test_loader)
- if loader_instance is not None:
- args['testLoader'] = loader_instance
+ if self.test_loader:
+ loader_class = resolve_name(self.test_loader)
+ if loader_class is not None:
+ args['testLoader'] = loader_class()
unittest.main(**args)
finally:
os.chdir(prev_cwd)