mirror of
https://github.com/httprunner/httprunner.git
synced 2026-06-10 18:29:37 +08:00
fix: compatibility for Python 2.7
This commit is contained in:
@@ -47,6 +47,7 @@ if is_py2:
|
||||
integer_types = (int, long)
|
||||
|
||||
FileNotFoundError = IOError
|
||||
import StringIO as io
|
||||
|
||||
elif is_py3:
|
||||
builtin_str = str
|
||||
@@ -57,3 +58,4 @@ elif is_py3:
|
||||
integer_types = (int,)
|
||||
|
||||
FileNotFoundError = FileNotFoundError
|
||||
import io as io
|
||||
|
||||
Reference in New Issue
Block a user