diff options
| author | Junio C Hamano <gitster@pobox.com> | 2021-09-15 13:15:26 -0700 |
|---|---|---|
| committer | Junio C Hamano <gitster@pobox.com> | 2021-09-15 13:15:26 -0700 |
| commit | 2b2af95908ec53e13be4506ece7acc0d82f981ae (patch) | |
| tree | 80870eaad139f25c42aeca3e52ee358bba632b56 /t/test-lib.sh | |
| parent | c76fcf3e46a86d389739b7ee94b3d4faa351af84 (diff) | |
| parent | 01c381037c30e9351e439d367983f88bdd3415ba (diff) | |
| download | git-2b2af95908ec53e13be4506ece7acc0d82f981ae.tar.xz | |
Merge branch 'pb/test-use-user-env'
Teach "test_pause" and "debug" helpers to allow using the HOME and
TERM environment variables the user usually uses.
* pb/test-use-user-env:
test-lib-functions: keep user's debugger config files and TERM in 'debug'
test-lib-functions: optionally keep HOME, TERM and SHELL in 'test_pause'
test-lib-functions: use 'TEST_SHELL_PATH' in 'test_pause'
Diffstat (limited to 't/test-lib.sh')
| -rw-r--r-- | t/test-lib.sh | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/t/test-lib.sh b/t/test-lib.sh index fc1e521519..d5ee964254 100644 --- a/t/test-lib.sh +++ b/t/test-lib.sh @@ -585,8 +585,9 @@ else } fi +USER_TERM="$TERM" TERM=dumb -export TERM +export TERM USER_TERM error () { say_color error "error: $*" @@ -1381,9 +1382,10 @@ then fi # Last-minute variable setup +USER_HOME="$HOME" HOME="$TRASH_DIRECTORY" GNUPGHOME="$HOME/gnupg-home-not-used" -export HOME GNUPGHOME +export HOME GNUPGHOME USER_HOME # Test repository rm -fr "$TRASH_DIRECTORY" || { |
