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

[PATCH v2 1/5] fix whitespace violations in test scripts

From
Jeff King <peff@peff.net>
Date
Jun 14, 2008, 07:25 UTC
Message-ID
<20080614072556.GA17536@sigill.intra.peff.net>
In-Reply-To
<20080614072214.GA9975@sigill.intra.peff.net>

These violations are simply wrong, but were never caught because whitespace policy checking is turned off in the test scripts.

Signed-off-by: Jeff King <peff@peff.net>
---
The original was total crap. t1502 didn't pass (which is now fixed in
3/4), and t3800 didn't pass (which is fixed correctly and lumped into
2/4 now).
 t/t3903-stash.sh        |    2 +-
 t/t4014-format-patch.sh |    6 +++---
 t/t4150-am.sh           |    2 +-
 t/t5540-http-push.sh    |    2 +-
 4 files changed, 6 insertions(+), 6 deletions(-)
diff --git a/t/t3903-stash.sh b/t/t3903-stash.sh
index 2d3ee3b..54d99ed 100755
--- a/t/t3903-stash.sh
+++ b/t/t3903-stash.sh
@@ -41,7 +41,7 @@ test_expect_success 'apply needs clean working directory' '
 	echo 4 > other-file &&
 	git add other-file &&
 	echo 5 > other-file &&
- 	test_must_fail git stash apply
+	test_must_fail git stash apply
 '
 
 test_expect_success 'apply stashed changes' '
diff --git a/t/t4014-format-patch.sh b/t/t4014-format-patch.sh
index 3583e68..7fe853c 100755
--- a/t/t4014-format-patch.sh
+++ b/t/t4014-format-patch.sh
@@ -98,7 +98,7 @@ test_expect_success 'extra headers' '
 	sed -e "/^$/q" patch2 > hdrs2 &&
 	grep "^To: R. E. Cipient <rcipient@example.com>$" hdrs2 &&
 	grep "^Cc: S. E. Cipient <scipient@example.com>$" hdrs2
-	
+
 '
 
 test_expect_success 'extra headers without newlines' '
@@ -109,7 +109,7 @@ test_expect_success 'extra headers without newlines' '
 	sed -e "/^$/q" patch3 > hdrs3 &&
 	grep "^To: R. E. Cipient <rcipient@example.com>$" hdrs3 &&
 	grep "^Cc: S. E. Cipient <scipient@example.com>$" hdrs3
-	
+
 '
 
 test_expect_success 'extra headers with multiple To:s' '
@@ -170,7 +170,7 @@ test_expect_success 'thread cover-letter' '
 	git checkout side &&
 	git format-patch --cover-letter --thread -o patches/ master &&
 	FIRST_MID=$(grep "Message-Id:" patches/0000-* | sed "s/^[^<]*\(<[^>]*>\).*$/\1/") &&
-	for i in patches/0001-* patches/0002-* patches/0003-* 
+	for i in patches/0001-* patches/0002-* patches/0003-*
 	do
 	  grep "References: $FIRST_MID" $i &&
 	  grep "In-Reply-To: $FIRST_MID" $i || break
diff --git a/t/t4150-am.sh b/t/t4150-am.sh
index 722ae96..bc98260 100755
--- a/t/t4150-am.sh
+++ b/t/t4150-am.sh
@@ -110,7 +110,7 @@ test_expect_success 'am applies patch correctly' '
 
 GIT_AUTHOR_NAME="Another Thor"
 GIT_AUTHOR_EMAIL="a.thor@example.com"
-GIT_COMMITTER_NAME="Co M Miter" 
+GIT_COMMITTER_NAME="Co M Miter"
 GIT_COMMITTER_EMAIL="c.miter@example.com"
 export GIT_AUTHOR_NAME GIT_AUTHOR_EMAIL GIT_COMMITTER_NAME GIT_COMMITTER_EMAIL
 
diff --git a/t/t5540-http-push.sh b/t/t5540-http-push.sh
index 7372439..f15dd03 100755
--- a/t/t5540-http-push.sh
+++ b/t/t5540-http-push.sh
@@ -38,7 +38,7 @@ test_expect_success 'setup remote repository' '
 	cd - &&
 	mv test_repo.git $HTTPD_DOCUMENT_ROOT_PATH
 '
-	
+
 test_expect_success 'clone remote repository' '
 	cd "$ROOT_PATH" &&
 	git clone $HTTPD_URL/test_repo.git test_repo_clone
-- 
1.5.6.rc2.183.g04614
Previous: Jeff KingNext: Jeff King
Message 10 of 19 in “t/.gitattributes: only ignore whitespace errors in test files”
  1. t/.gitattributes: only ignore whitespace errors in test filesLea Wiemann, Jun 12, 2008
  2. Jeff KingJun 13, 2008
  3. t/.gitattributes: only ignore whitespace errors in test filesLea Wiemann, Jun 13, 2008
  4. Junio C HamanoJun 13, 2008
  5. Jeff KingJun 14, 2008
  6. 1/4 fix whitespace violations in test scriptsJeff King, Jun 14, 2008
  7. Jeff KingJun 14, 2008
  8. Junio C HamanoJun 14, 2008
  9. Jeff KingJun 14, 2008
  10. 1/5 fix whitespace violations in test scriptsJeff King, Jun 14, 2008
  11. 2/5 mask necessary whitespace policy violations in test scriptsJeff King, Jun 14, 2008
  12. 3/5 avoid whitespace on empty line in automatic usage messageJeff King, Jun 14, 2008
  13. 4/5 avoid trailing whitespace in zero-change diffstat linesJeff King, Jun 14, 2008
  14. 5/5 enable whitespace checking of test scriptsJeff King, Jun 14, 2008
  15. 2/4 mask necessary whitespace policy violations in test scriptsJeff King, Jun 14, 2008
  16. 3/4 avoid trailing whitespace in zero-change diffstat linesJeff King, Jun 14, 2008
  17. Junio C HamanoJun 14, 2008
  18. Jeff KingJun 14, 2008
  19. 4/4 enable whitespace checking of test scriptsJeff King, Jun 14, 2008

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.