Merge branch 'ab/dynamic-gettext-poison'
[gitweb.git] / t / test-lib-functions.sh
index d158c8d0bf704646b2ce764fe96a849fb0303c2f..4397c01be03b376b7eb942c0e89032190ad82313 100644 (file)
@@ -778,16 +778,16 @@ test_cmp_bin() {
 
 # Use this instead of test_cmp to compare files that contain expected and
 # actual output from git commands that can be translated.  When running
-# under GETTEXT_POISON this pretends that the command produced expected
+# under GIT_TEST_GETTEXT_POISON this pretends that the command produced expected
 # results.
 test_i18ncmp () {
-       test -n "$GETTEXT_POISON" || test_cmp "$@"
+       ! test_have_prereq C_LOCALE_OUTPUT || test_cmp "$@"
 }
 
 # Use this instead of "grep expected-string actual" to see if the
 # output from a git command that can be translated either contains an
 # expected string, or does not contain an unwanted one.  When running
-# under GETTEXT_POISON this pretends that the command produced expected
+# under GIT_TEST_GETTEXT_POISON this pretends that the command produced expected
 # results.
 test_i18ngrep () {
        eval "last_arg=\${$#}"
@@ -802,7 +802,7 @@ test_i18ngrep () {
                error "bug in the test script: too few parameters to test_i18ngrep"
        fi
 
-       if test -n "$GETTEXT_POISON"
+       if test_have_prereq !C_LOCALE_OUTPUT
        then
                # pretend success
                return 0