diff options
author | Junio C Hamano <gitster@pobox.com> | 2012-12-18 20:41:15 -0800 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2012-12-19 07:46:59 -0800 |
commit | 5a029666858d11e66eb689bba1c6435e8b9d0979 (patch) | |
tree | 4ff934dc507be51ddec286b81134144b7a4459b9 /t/t9020-remote-svn.sh | |
parent | 2d3ac9ad67b7038e1046dad3b1a273ba29282f31 (diff) | |
download | git-5a029666858d11e66eb689bba1c6435e8b9d0979.tar.gz git-5a029666858d11e66eb689bba1c6435e8b9d0979.tar.xz |
t9020: use configured Python to run the test helper
The test helper svnrdump_sim.py is used as "svnrdump" during the
execution of this test, but the arrangement was not optimal:
- it relied on symbolic links;
- unportable "export VAR=VAL" was used;
- GIT_BUILD_DIR variable was not quoted correctly;
- it assumed that the Python interpreter is in /usr/bin/ and
called "python" (i.e. not "python2.7" etc.)
Rework this by writing a small shell script that spawns the right
Python interpreter, using the right quoting.
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't/t9020-remote-svn.sh')
-rwxr-xr-x | t/t9020-remote-svn.sh | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/t/t9020-remote-svn.sh b/t/t9020-remote-svn.sh index 4f2dfe0e3..d7be66a1d 100755 --- a/t/t9020-remote-svn.sh +++ b/t/t9020-remote-svn.sh @@ -12,9 +12,13 @@ then test_done fi -# We override svnrdump by placing a symlink to the svnrdump-emulator in . -export PATH="$HOME:$PATH" -ln -sf $GIT_BUILD_DIR/contrib/svn-fe/svnrdump_sim.py "$HOME/svnrdump" +# Override svnrdump with our simulator +PATH="$HOME:$PATH" +export PATH PYTHON_PATH GIT_BUILD_DIR + +write_script "$HOME/svnrdump" <<\EOF +exec "$PYTHON_PATH" "$GIT_BUILD_DIR/contrib/svn-fe/svnrdump_sim.py" "$@" +EOF init_git () { rm -fr .git && |