From 76754ff2baf198904cabe210d1ed005433370266 Mon Sep 17 00:00:00 2001 From: echel0n Date: Sat, 13 Dec 2014 15:16:11 -0800 Subject: [PATCH] PEP8 performed on unitests --- tests/db_tests.py | 2 +- tests/encoding_tests.py | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/tests/db_tests.py b/tests/db_tests.py index f1dedbd2..5b52e704 100644 --- a/tests/db_tests.py +++ b/tests/db_tests.py @@ -38,7 +38,7 @@ class DBMultiTests(test.SickbeardTestDBCase): self.db.select("SELECT * FROM tv_episodes WHERE showid = ? AND location != ''", [0000]) def test_threaded(self): - for i in xrange(20): + for i in xrange(4): t = threading.Thread(target=self.select) t.start() diff --git a/tests/encoding_tests.py b/tests/encoding_tests.py index 0333ec9c..9aa429c2 100644 --- a/tests/encoding_tests.py +++ b/tests/encoding_tests.py @@ -11,15 +11,14 @@ from sickbeard.exceptions import ex sickbeard.SYS_ENCODING = 'UTF-8' -DEBUG = VERBOSE = False - class EncodingTests(unittest.TestCase): def test_encoding(self): strings = [u'Les Enfants De La Télé'] for s in strings: try: - print 'Encoded: ' + ek.ss(s) + x = ek.ss(s) + assert isinstance(x, unicode) except Exception, e: ex(e) @@ -28,4 +27,5 @@ if __name__ == "__main__": print "STARTING - Encoding TESTS" print "==================" print "######################################################################" - suite = unittest.TestLoader().loadTestsFromTestCase(EncodingTests) \ No newline at end of file + suite = unittest.TestLoader().loadTestsFromTestCase(EncodingTests) + unittest.TextTestRunner(verbosity=2).run(suite) \ No newline at end of file