Fix encoding errors for parametrized tests with unicode parameters in py2
Fix #1085
This commit is contained in:
@@ -1093,7 +1093,7 @@ def _idval(val, argname, idx, idfn):
|
||||
# convertible to ascii, return it as an str() object instead
|
||||
try:
|
||||
return str(val)
|
||||
except UnicodeDecodeError:
|
||||
except UnicodeError:
|
||||
# fallthrough
|
||||
pass
|
||||
return str(argname)+str(idx)
|
||||
|
||||
Reference in New Issue
Block a user