git/ci
SZEDER Gábor 60e47f6773 ci: use absolute PYTHON_PATH in the Linux jobs
In our test suite, when 'git p4' invokes a Git command as a
subprocesses, then it should run the 'git' binary we are testing.
Unfortunately, this is not the case in the 'linux-clang' and
'linux-gcc' jobs on Travis CI, where 'git p4' runs the system
'/usr/bin/git' instead.

Travis CI's default Linux image includes 'pyenv', and all Python
invocations that involve PATH lookup go through 'pyenv', e.g. our
'PYTHON_PATH=$(which python3)' sets '/opt/pyenv/shims/python3' as
PYTHON_PATH, which in turn will invoke '/usr/bin/python3'.  Alas, the
'pyenv' version included in this image is buggy, and prepends the
directory containing the Python binary to PATH even if that is a
system directory already in PATH near the end.  Consequently, 'git p4'
in those jobs ends up with its PATH starting with '/usr/bin', and then
runs '/usr/bin/git'.

So use the absolute paths '/usr/bin/python{2,3}' explicitly when
setting PYTHON_PATH in those Linux jobs to avoid the PATH lookup and
thus the bogus 'pyenv' from interfering with our 'git p4' tests.
Don't bother with special-casing Travis CI: while this issue doesn't
affect the corresponding Linux jobs on GitHub Actions, both CI systems
use Ubuntu LTS-based images, so we can safely rely on these Python
paths.

Signed-off-by: SZEDER Gábor <szeder.dev@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2020-07-23 15:32:06 -07:00
..
config ci/config: correct instruction for CI preferences 2020-05-18 10:18:34 -07:00
util travis-ci: include the trash directories of failed tests in the trace log 2018-08-01 09:59:36 -07:00
install-dependencies.sh ci: run gem with sudo to install asciidoctor 2020-04-10 10:30:40 -07:00
install-docker-dependencies.sh travis: build and test on Linux with musl libc and busybox 2020-04-06 13:44:42 -07:00
lib.sh ci: use absolute PYTHON_PATH in the Linux jobs 2020-07-23 15:32:06 -07:00
make-test-artifacts.sh ci: parallelize testing on Windows 2019-01-29 09:26:47 -08:00
mount-fileshare.sh Add a build definition for Azure DevOps 2019-01-29 09:26:46 -08:00
print-test-failures.sh ci: let GitHub Actions upload failed tests' directories 2020-04-10 10:30:40 -07:00
run-build-and-tests.sh commit-graph: add GIT_TEST_COMMIT_GRAPH_CHANGED_PATHS test flag 2020-04-06 11:08:37 -07:00
run-docker-build.sh travis: build and test on Linux with musl libc and busybox 2020-04-06 13:44:42 -07:00
run-docker.sh travis: build and test on Linux with musl libc and busybox 2020-04-06 13:44:42 -07:00
run-static-analysis.sh ci: run hdr-check as part of the Static Analysis job 2019-10-03 10:34:57 +09:00
run-test-slice.sh ci: parallelize testing on Windows 2019-01-29 09:26:47 -08:00
test-documentation.sh ci: ignore rubygems warning in the "Documentation" job 2020-02-10 09:52:27 -08:00