From 147752268175333efa2045cf599f2f2482e5e7dc Mon Sep 17 00:00:00 2001 From: Manuel Cortez Date: Thu, 23 Jul 2020 06:09:28 -0500 Subject: [PATCH] removed i18n from the test suite [Skip CI] --- src/run_tests.py | 2 +- src/test/test_i18n.py | 28 ---------------------------- 2 files changed, 1 insertion(+), 29 deletions(-) delete mode 100644 src/test/test_i18n.py diff --git a/src/run_tests.py b/src/run_tests.py index f867680..604aed0 100644 --- a/src/run_tests.py +++ b/src/run_tests.py @@ -1,7 +1,7 @@ # -*- coding: utf-8 -*- import unittest -testmodules = ['test.test_fixes', 'test.test_storage', 'test.test_services', 'test.test_i18n'] +testmodules = ['test.test_fixes', 'test.test_storage', 'test.test_services'] suite = unittest.TestSuite() diff --git a/src/test/test_i18n.py b/src/test/test_i18n.py deleted file mode 100644 index 02b65fa..0000000 --- a/src/test/test_i18n.py +++ /dev/null @@ -1,28 +0,0 @@ -# -*- coding: utf-8 -*- -""" Unittests for internationalization features. This test is here for avoiding breaking things between gettext for python 2 and 3. """ -from __future__ import unicode_literals -import os -import unittest -import sys -import i18n - -# Python 2/3 compat. -if sys.version[0] == "2": - strtype = unicode -else: - strtype = str - -class i18nTestCase(unittest.TestCase): - - def test_i18n_unicode(self): - """ Testing gettext function so it will generate only unicode strings both in python 2 and 3. """ - i18n.setup() - # If something happened to i18n, it should raise a traceback in the next call - translated_str = _("This is a string with no special characters.") - self.assertIsInstance(translated_str, strtype) - # Test something with a special character here. - localized_fake_str = _("Привет всем") - self.assertIsInstance(localized_fake_str, strtype) - -if __name__ == "__main__": - unittest.main() \ No newline at end of file