zerver/tests/test_i18n.py: Ignore due to incomplete stubs.

In python 3, http.cookies has incomplete stubs.
This commit is contained in:
Eklavya Sharma 2016-07-05 09:48:59 +05:30 committed by Tim Abbott
parent 6c3f1bb967
commit 4cf7641ab1
2 changed files with 2 additions and 3 deletions

View File

@ -41,7 +41,6 @@ exclude_py2 = []
exclude_py3 = """
zerver/lib/ccache.py
zerver/tests/test_i18n.py
""".split()
parser = argparse.ArgumentParser(description="Run mypy on files tracked by git.")

View File

@ -7,7 +7,7 @@ import mock
from django.test import TestCase
from django.conf import settings
from django.http import HttpResponse
from http.cookies import SimpleCookie
from six.moves.http_cookies import SimpleCookie
from zerver.lib.test_helpers import AuthedTestCase
@ -49,7 +49,7 @@ class TranslationTestCase(TestCase):
]
for lang, word in languages:
self.client.cookies = SimpleCookie({settings.LANGUAGE_COOKIE_NAME: lang})
self.client.cookies = SimpleCookie({settings.LANGUAGE_COOKIE_NAME: lang}) # type: ignore # SimpleCookie has incomplete stubs in python 3
response = self.fetch('get', '/integrations/', 200)
self.assertTrue(word in response.content)