From 0bc88c0cd049af0ce654655c4f0d80e00d59ac65 Mon Sep 17 00:00:00 2001 From: Manuel Cortez Date: Sun, 30 Dec 2018 10:34:33 -0600 Subject: [PATCH] Added tests for unicode strings in searches --- src/test/test_extractors.py | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/src/test/test_extractors.py b/src/test/test_extractors.py index 46a9270..c0a79b4 100644 --- a/src/test/test_extractors.py +++ b/src/test/test_extractors.py @@ -57,6 +57,10 @@ class extractorsTestCase(unittest.TestCase): """ Testing a Youtube search. """ self.search("youtube") + def test_youtube_search_unicode(self): + """ Testing a Youtube search using unicode characters. """ + self.search("youtube", "Пианино") + def test_youtube_search_blank(self): """ Testing a youtube search when text is blank or not passed. """ self.search_blank("youtube") @@ -73,6 +77,10 @@ class extractorsTestCase(unittest.TestCase): """ Testing a mail.ru search. """ self.search("mailru") + def test_mailru_search_unicode(self): + """ Testing a mail.ru search with unicode characters. """ + self.search("mailru", "Пианино") + def test_mailru_search_blank(self): """ Testing a mail.ru search when text is blank. """ self.search_blank("mailru") @@ -81,6 +89,10 @@ class extractorsTestCase(unittest.TestCase): """ Testing a search made in zaycev.net """ self.search("zaycev") + def test_zaycev_search_unicode(self): + """ Testing a search made in zaycev.net with unicode characters. """ + self.search("zaycev", "Пианино") + def test_zaycev_search_blank(self): """ Testing a search in zaycev.net when text is blank. """ self.search_blank("zaycev")