git/list[1] front-page[2] threads[3] people[4] search[5] about
 

[PATCH 1/2] t0205: drop redundant test

From
Jeff King <peff@peff.net>
Date
Feb 6, 2018, 08:43 UTC
Message-ID
<20180206084318.GA26329@sigill.intra.peff.net>
In-Reply-To
<20180206084226.GA26237@sigill.intra.peff.net>

We check that a shell variable is non-empty, and then we check that it's equal to a particular value. Just checking the latter covers both cases.

I suspect the original was trying to give better output when the test fails, but using "-x" covers that these days.

Signed-off-by: Jeff King <peff@peff.net>
---
 t/t0205-gettext-poison.sh | 4 ----
 1 file changed, 4 deletions(-)
diff --git a/t/t0205-gettext-poison.sh b/t/t0205-gettext-poison.sh
index 2361590d54..438e778d6a 100755
--- a/t/t0205-gettext-poison.sh
+++ b/t/t0205-gettext-poison.sh
@@ -7,10 +7,6 @@ test_description='Gettext Shell poison'
 
 . ./lib-gettext.sh
 
-test_expect_success GETTEXT_POISON "sanity: \$GIT_INTERNAL_GETTEXT_SH_SCHEME is set (to $GIT_INTERNAL_GETTEXT_SH_SCHEME)" '
-    test -n "$GIT_INTERNAL_GETTEXT_SH_SCHEME"
-'
-
 test_expect_success GETTEXT_POISON 'sanity: $GIT_INTERNAL_GETTEXT_SH_SCHEME" is poison' '
     test "$GIT_INTERNAL_GETTEXT_SH_SCHEME" = "poison"
 '
-- 
2.16.1.273.gc07cfcd8c9
Previous: Jeff KingNext: Jeff King
Message 2 of 5 in “minor GETTEXT_POISON fixes”
  1. 0/2 minor GETTEXT_POISON fixesJeff King, Feb 6, 2018
  2. 1/2 t0205: drop redundant testJeff King, Feb 6, 2018
  3. 2/2 git-sh-i18n: check GETTEXT_POISON before USE_GETTEXT_SCHEMEJeff King, Feb 6, 2018
  4. Lars SchneiderFeb 6, 2018
  5. Jeff KingFeb 6, 2018

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.