summaryrefslogtreecommitdiff
path: root/_pytest
diff options
context:
space:
mode:
authorFloris Bruynooghe <flub@devork.be>2013-10-01 13:20:20 +0100
committerFloris Bruynooghe <flub@devork.be>2013-10-01 13:20:20 +0100
commit1db6fc87c73e9ef51f7e4f47af5a0a953c5f8cdf (patch)
tree5fd4fa5087dc65c25a6bc155cc4ebf991dad23f8 /_pytest
parent895d52471bbd7d99c31c3f727d0233431131c835 (diff)
downloadpytest-1db6fc87c73e9ef51f7e4f47af5a0a953c5f8cdf.tar.gz
Allow unicode strings in parser.add_argument()
This fixes issue360 by also converting unicode strings to the argparse syntax instead of just native strings.
Diffstat (limited to '_pytest')
-rw-r--r--_pytest/config.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/_pytest/config.py b/_pytest/config.py
index 72276f853..36fb56425 100644
--- a/_pytest/config.py
+++ b/_pytest/config.py
@@ -238,7 +238,7 @@ class Argument:
pass
else:
# this might raise a keyerror as well, don't want to catch that
- if isinstance(typ, str):
+ if isinstance(typ, py.builtin._basestring):
if typ == 'choice':
if self.TYPE_WARN:
py.std.warnings.warn(