Skip to content

Commit

Permalink
fix python2.7 tests
Browse files Browse the repository at this point in the history
  • Loading branch information
noviluni committed Mar 6, 2020
1 parent b0cb337 commit 4e551f2
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions tests/test_parser.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
# coding: utf-8

from datetime import datetime, time

from parameterized import parameterized, param
Expand Down Expand Up @@ -50,7 +52,7 @@ class TestTokenizer(BaseTestCase):
),
param(
date_string=u"Oct 1 2018 4:40 PM EST —",
expected_tokens=['Oct', ' ', '1', ' ', '2018', ' ', '4:40', ' ', 'PM', ' ', 'EST', ' —'],
expected_tokens=['Oct', ' ', '1', ' ', '2018', ' ', '4:40', ' ', 'PM', ' ', 'EST', u' —'],
expected_types=[1, 2, 0, 2, 0, 2, 0, 2, 1, 2, 1, 2],
),
param(
Expand All @@ -64,8 +66,8 @@ class TestTokenizer(BaseTestCase):
expected_types=[1],
),
param(
date_string= "./\()\"',.;<>~!@#$%^&*|+=[]{}`~?-—– 😊", # unrecognized characters
expected_tokens=["./\()\"',.;<>~!@#$%^&*|+=[]{}`~?-—– 😊"],
date_string=u"./\()\"',.;<>~!@#$%^&*|+=[]{}`~?-—– 😊", # unrecognized characters
expected_tokens=[u"./\()\"',.;<>~!@#$%^&*|+=[]{}`~?-—– 😊"],
expected_types=[2],
),
])
Expand Down

0 comments on commit 4e551f2

Please sign in to comment.