[Test] remove unnecessary Python check
we only support Python 3
This commit is contained in:
@@ -21,8 +21,6 @@
|
||||
#* *
|
||||
#***************************************************************************/
|
||||
|
||||
|
||||
import sys
|
||||
import os
|
||||
import ast
|
||||
import unittest
|
||||
@@ -35,8 +33,7 @@ def test_python_syntax(rootdir, whitelist=None):
|
||||
for sub_dir, dirs, files in os.walk(rootdir):
|
||||
for fn in files:
|
||||
kargs = {}
|
||||
if sys.version_info.major >= 3:
|
||||
kargs["encoding"] = "utf-8"
|
||||
kargs["encoding"] = "utf-8"
|
||||
if (not fn in whitelist) and os.path.splitext(fn)[1] == '.py':
|
||||
with open(os.path.join(sub_dir, fn), **kargs) as py_file:
|
||||
try:
|
||||
|
||||
Reference in New Issue
Block a user