diff options
| author | Junio C Hamano <gitster@pobox.com> | 2019-07-25 13:59:20 -0700 |
|---|---|---|
| committer | Junio C Hamano <gitster@pobox.com> | 2019-07-25 13:59:20 -0700 |
| commit | 023ff4cdf5793437313f481b4ef5b1ec247f2301 (patch) | |
| tree | fe222b4b3edeb442b7873d89d03556a1e11c1274 /t/lib-git-daemon.sh | |
| parent | 9c9b961d7eb15fb583a2a812088713a68a85f1c0 (diff) | |
| parent | 08a8ac88d868f3206e8faf0df2502ebc18925c33 (diff) | |
| download | git-023ff4cdf5793437313f481b4ef5b1ec247f2301.tar.xz | |
Merge branch 'ab/test-env'
Many GIT_TEST_* environment variables control various aspects of
how our tests are run, but a few followed "non-empty is true, empty
or unset is false" while others followed the usual "there are a few
ways to spell true, like yes, on, etc., and also ways to spell
false, like no, off, etc." convention.
* ab/test-env:
env--helper: mark a file-local symbol as static
tests: make GIT_TEST_FAIL_PREREQS a boolean
tests: replace test_tristate with "git env--helper"
tests README: re-flow a previously changed paragraph
tests: make GIT_TEST_GETTEXT_POISON a boolean
t6040 test: stop using global "script" variable
config.c: refactor die_bad_number() to not call gettext() early
env--helper: new undocumented builtin wrapping git_env_*()
config tests: simplify include cycle test
Diffstat (limited to 't/lib-git-daemon.sh')
| -rw-r--r-- | t/lib-git-daemon.sh | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/t/lib-git-daemon.sh b/t/lib-git-daemon.sh index 7b3407134e..fb8f887080 100644 --- a/t/lib-git-daemon.sh +++ b/t/lib-git-daemon.sh @@ -15,8 +15,7 @@ # # test_done -test_tristate GIT_TEST_GIT_DAEMON -if test "$GIT_TEST_GIT_DAEMON" = false +if ! git env--helper --type=bool --default=true --exit-code GIT_TEST_GIT_DAEMON then skip_all="git-daemon testing disabled (unset GIT_TEST_GIT_DAEMON to enable)" test_done @@ -24,7 +23,7 @@ fi if test_have_prereq !PIPE then - test_skip_or_die $GIT_TEST_GIT_DAEMON "file system does not support FIFOs" + test_skip_or_die GIT_TEST_GIT_DAEMON "file system does not support FIFOs" fi test_set_port LIB_GIT_DAEMON_PORT @@ -73,7 +72,7 @@ start_git_daemon() { kill "$GIT_DAEMON_PID" wait "$GIT_DAEMON_PID" unset GIT_DAEMON_PID - test_skip_or_die $GIT_TEST_GIT_DAEMON \ + test_skip_or_die GIT_TEST_GIT_DAEMON \ "git daemon failed to start" fi } |
