diff options
author | Jason R. Coombs <jaraco@jaraco.com> | 2015-10-10 20:03:33 -0400 |
---|---|---|
committer | Jason R. Coombs <jaraco@jaraco.com> | 2015-10-10 20:03:33 -0400 |
commit | a33e201d1a86dd108e8641f641ff24c7f00ba054 (patch) | |
tree | b97cfba1858c5f55fa729e544c3661e9f8787c54 /setuptools/command/test.py | |
parent | 0a30d49169f5e73c86f452f284d10ed4b1646ff4 (diff) | |
download | external_python_setuptools-a33e201d1a86dd108e8641f641ff24c7f00ba054.tar.gz external_python_setuptools-a33e201d1a86dd108e8641f641ff24c7f00ba054.tar.bz2 external_python_setuptools-a33e201d1a86dd108e8641f641ff24c7f00ba054.zip |
Move value checking into its own block.
Diffstat (limited to 'setuptools/command/test.py')
-rw-r--r-- | setuptools/command/test.py | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/setuptools/command/test.py b/setuptools/command/test.py index a80d91ad..4d859808 100644 --- a/setuptools/command/test.py +++ b/setuptools/command/test.py @@ -62,15 +62,16 @@ class test(Command): def finalize_options(self): + if self.test_suite and self.test_module: + raise DistutilsOptionError( + "You may specify a module or a suite, but not both" + ) + if self.test_suite is None: if self.test_module is None: self.test_suite = self.distribution.test_suite else: self.test_suite = self.test_module + ".test_suite" - elif self.test_module: - raise DistutilsOptionError( - "You may specify a module or a suite, but not both" - ) if self.test_loader is None: self.test_loader = getattr(self.distribution, 'test_loader', None) |