Commit 98ce110a by Tim Babych

add test for unicode search

parent a836bcc7
...@@ -331,17 +331,17 @@ class AnnotationViewTests(BaseAnnotationViewTests): ...@@ -331,17 +331,17 @@ class AnnotationViewTests(BaseAnnotationViewTests):
self.assertEqual(results['rows'][1]['text'], 'Second note') self.assertEqual(results['rows'][1]['text'], 'Second note')
self.assertEqual(results['rows'][2]['text'], 'First one') self.assertEqual(results['rows'][2]['text'], 'First one')
# def test_search_unicode(self): def test_search_unicode(self):
# """ """
# Tests searching of unicode strings. Tests searching of unicode strings.
# """ """
# self._create_annotation(text=u'Веселих свят') self._create_annotation(text=u'Веселих свят')
# results = self._get_search_results(text=u"веселих".encode('utf-8')) results = self._get_search_results(text=u"веселих")
# self.assertEqual(results['total'], 1) self.assertEqual(results['total'], 1)
# results = self._get_search_results(text=u"свят") results = self._get_search_results(text=u"свят")
# self.assertEqual(results['total'], 1) self.assertEqual(results['total'], 1)
def test_read_all_no_annotations(self): def test_read_all_no_annotations(self):
""" """
......
Django==1.7.1 Django==1.7.1
requests==2.4.3 requests==2.4.3
djangorestframework==2.4.4 djangorestframework==3.0.2
django-rest-swagger==0.2.0 django-rest-swagger==0.2.0
elasticutils==0.10 elasticutils==0.10
elasticsearch==1.2.0 elasticsearch==1.2.0
......
-r base.txt -r base.txt
# unicode QUERY_PARAMS are being improperly decoded in test client
# remove after https://github.com/tomchristie/django-rest-framework/issues/1891 is fixed
-e git+https://github.com/tymofij/django-rest-framework.git@bugfix/test-unicode-query-params#egg=djangorestframework
django_nose==1.2 django_nose==1.2
mock==1.0.1 mock==1.0.1
coverage==3.7.1 coverage==3.7.1
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment