summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: d599e04)
raw | patch | inline | side by side (parent: d599e04)
author | Michael J Gruber <git@drmicha.warpmail.net> | |
Thu, 22 Apr 2010 20:30:19 +0000 (22:30 +0200) | ||
committer | Junio C Hamano <gitster@pobox.com> | |
Thu, 6 May 2010 20:22:37 +0000 (13:22 -0700) |
edf563f (status: make "how to stage" messages optional, 2009-09-09)
introduced advice.statusHints without tests. Add a few tests to describe
and test the status quo.
Signed-off-by: Michael J Gruber <git@drmicha.warpmail.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
introduced advice.statusHints without tests. Add a few tests to describe
and test the status quo.
Signed-off-by: Michael J Gruber <git@drmicha.warpmail.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
t/t7508-status.sh | patch | blob | history |
diff --git a/t/t7508-status.sh b/t/t7508-status.sh
index 556d0faa77e027c8a18e213088fa6bbc5d7e7af5..7409a06c0b40b511d208430c0506dc8b3a1b2429 100755 (executable)
--- a/t/t7508-status.sh
+++ b/t/t7508-status.sh
'
+cat >expect <<\EOF
+# On branch master
+# Changes to be committed:
+# new file: dir2/added
+#
+# Changed but not updated:
+# modified: dir1/modified
+#
+# Untracked files:
+# dir1/untracked
+# dir2/modified
+# dir2/untracked
+# expect
+# output
+# untracked
+EOF
+
+git config advice.statusHints false
+
+test_expect_success 'status (advice.statusHints false)' '
+
+ git status >output &&
+ test_cmp expect output
+
+'
+
+git config --unset advice.statusHints
+
cat >expect <<\EOF
M dir1/modified
A dir2/added
test_cmp expect output
'
+cat >expect <<EOF
+# On branch master
+# Changes to be committed:
+# new file: dir2/added
+#
+# Changed but not updated:
+# modified: dir1/modified
+#
+# Untracked files not listed (use -u option to show untracked files)
+EOF
+git config advice.statusHints false
+test_expect_success 'status -uno (advice.statusHints false)' '
+ git status -uno >output &&
+ test_cmp expect output
+'
+git config --unset advice.statusHints
+
cat >expect << EOF
M dir1/modified
A dir2/added