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

[PATCH v4 4/6] t1308: relax the test verifying that empty alias values are disallowed

From
Johannes Schindelin <johannes.schindelin@gmx.de>
Date
Jun 14, 2017, 11:35 UTC
Message-ID
<2c480fe5c160c560b501b6190a95154ef6b19ba7.1497440104.git.johannes.schindelin@gmx.de>
In-Reply-To
<cover.1497440104.git.johannes.schindelin@gmx.de>

We are about to change the way aliases are expanded, to use the early config machinery.

This machinery reports errors in a slightly different manner than the cached config machinery.

Let's not get hung up by the precise wording of the message mentioning the line number. It is really sufficient to verify that all the relevant information is given to the user.

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
---
 t/t1308-config-set.sh | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/t/t1308-config-set.sh b/t/t1308-config-set.sh
index e495a616161..bafed5c9b88 100755
--- a/t/t1308-config-set.sh
+++ b/t/t1308-config-set.sh
@@ -226,7 +226,9 @@ test_expect_success 'check line errors for malformed values' '
 		br
 	EOF
 	test_expect_code 128 git br 2>result &&
-	test_i18ngrep "fatal: .*alias\.br.*\.git/config.*line 2" result
+	test_i18ngrep "missing value for .alias\.br" result &&
+	test_i18ngrep "fatal: .*\.git/config" result &&
+	test_i18ngrep "fatal: .*line 2" result
 '
 
 test_expect_success 'error on modifying repo config without repo' '
-- 
2.13.1.windows.1.1.ga36e14b3aaa
Previous: Johannes SchindelinNext: Johannes Schindelin
Message 4 of 10 in “Avoid problem where git_dir is set after alias expansion”
  1. 0/6 Avoid problem where git_dir is set after alias expansionJohannes Schindelin, Jun 14, 2017
  2. 1/6 discover_git_directory(): avoid setting invalid git_dirJohannes Schindelin, Jun 14, 2017
  3. 3/6 help: use early config when autocorrecting aliasesJohannes Schindelin, Jun 14, 2017
  4. 4/6 t1308: relax the test verifying that empty alias values are disallowedJohannes Schindelin, Jun 14, 2017
  5. 2/6 config: report correct line number upon errorJohannes Schindelin, Jun 14, 2017
  6. 5/6 t7006: demonstrate a problem with aliases in subdirectoriesJohannes Schindelin, Jun 14, 2017
  7. 6/6 Use the early config machinery to expand aliasesJohannes Schindelin, Jun 14, 2017
  8. Junio C HamanoJun 15, 2017
  9. Johannes SchindelinJun 15, 2017
  10. Jeff KingJun 15, 2017

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.