Fix ansible-test python and pip executable search.

This commit is contained in:
Matt Clay 2018-03-14 11:35:59 -07:00
parent dd37857884
commit a8487feb70
14 changed files with 81 additions and 75 deletions

View file

@ -15,7 +15,6 @@ from lib.util import (
SubprocessError,
display,
run_command,
find_executable,
)
from lib.config import (
@ -56,8 +55,8 @@ class Pep8Test(SanitySingleVersion):
paths = sorted(i.path for i in targets.include if (os.path.splitext(i.path)[1] == '.py' or i.path.startswith('bin/')) and i.path not in skip_paths_set)
cmd = [
'python%s' % args.python_version,
find_executable('pycodestyle'),
args.python_executable,
'-m', 'pycodestyle',
'--max-line-length', '160',
'--config', '/dev/null',
'--ignore', ','.join(sorted(current_ignore)),