aboutsummaryrefslogtreecommitdiffstats
path: root/setup.py
diff options
context:
space:
mode:
authorMatěj Cepl <mcepl@redhat.com>2014-02-11 09:34:59 +0100
committerMatěj Cepl <mcepl@redhat.com>2014-02-13 02:01:54 +0100
commit23a64455b1d30b5ed71ac58cb786aeeb54f168c2 (patch)
treef736d340a7cf8e2ae69a10a851a1c7f003316a76 /setup.py
parent31152dadf548370abb25e93bbdf4359c8b155433 (diff)
downloadgg_scraper-23a64455b1d30b5ed71ac58cb786aeeb54f168c2.tar.gz
Fix setup.py.RunTests.run() to return proper exit code.
The previous situation didn't fail on Travis-CI. But this does, so I had to include also a number of fixes for revealed issues. Fixing #314, #315, #316, and #317
Diffstat (limited to 'setup.py')
-rw-r--r--setup.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/setup.py b/setup.py
index 331e57e..3695fad 100644
--- a/setup.py
+++ b/setup.py
@@ -1,5 +1,6 @@
# -*- coding: utf-8 -*-
from __future__ import absolute_import, print_function, unicode_literals
+import sys
from distutils.core import setup, Command
try:
import unittest2 as unittest
@@ -25,7 +26,8 @@ class RunTests(Command):
def run(self):
tests = unittest.TestLoader().discover('test')
runner = unittest.TextTestRunner(verbosity=2)
- runner.run(tests)
+ res = runner.run(tests)
+ sys.exit(int(not res.wasSuccessful()))
classifiers = [