Skip to content

Commit

Permalink
unicode() --> six.u() for Python 3 compatibility (#111)
Browse files Browse the repository at this point in the history
__unicode()__ was removed from Python 3 because all strs are unicode.

Executing these lines in Python 3 would raise a NameError.

* https://pythonhosted.org/six/#six.u
  • Loading branch information
cclauss authored and dbieber committed Jan 11, 2018
1 parent 7f166e9 commit 9bff9d0
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions fire/parser_fuzz_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -67,8 +67,8 @@ def testDefaultParseValueFuzz(self, value):
raise

try:
uvalue = unicode(value)
uresult = unicode(result)
uvalue = six.u(value)
uresult = six.u(result)
except UnicodeDecodeError:
# This is not what we're testing.
return
Expand Down

0 comments on commit 9bff9d0

Please sign in to comment.