aboutsummaryrefslogtreecommitdiff
path: root/t/t7508-status.sh
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2009-08-15 02:27:39 -0700
committerJunio C Hamano <gitster@pobox.com>2009-08-22 12:18:00 -0700
commit9e4b7ab652561e1807702fe5288e04b8873fc437 (patch)
tree468f28135714375fa664bfebf4a0fa0f71582d54 /t/t7508-status.sh
parent173e6c8852be3c543689f8613ddf3fdafd9ca7b9 (diff)
downloadgit-9e4b7ab652561e1807702fe5288e04b8873fc437.tar.gz
git-9e4b7ab652561e1807702fe5288e04b8873fc437.tar.xz
git status: not "commit --dry-run" anymore
This removes tentative "git stat" and make it take over "git status". There are some tests that expect "git status" to exit with non-zero status when there is something staged. Some tests expect "git status path..." to show the status for a partial commit. For these, replace "git status" with "git commit --dry-run". For the ones that do not attempt a dry-run of a partial commit that check the output from the command, check the output from "git status" as well, as they should be identical. Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't/t7508-status.sh')
-rwxr-xr-xt/t7508-status.sh12
1 files changed, 7 insertions, 5 deletions
diff --git a/t/t7508-status.sh b/t/t7508-status.sh
index 93f875f50..1173dbb36 100755
--- a/t/t7508-status.sh
+++ b/t/t7508-status.sh
@@ -248,8 +248,8 @@ cat <<EOF >expect
# output
# untracked
EOF
-test_expect_success 'status of partial commit excluding new file in index' '
- git status dir1/modified >output &&
+test_expect_success 'dry-run of partial commit excluding new file in index' '
+ git commit --dry-run dir1/modified >output &&
test_cmp expect output
'
@@ -358,7 +358,9 @@ EOF
test_expect_success 'status submodule summary (clean submodule)' '
git commit -m "commit submodule" &&
git config status.submodulesummary 10 &&
- test_must_fail git status >output &&
+ test_must_fail git commit --dry-run >output &&
+ test_cmp expect output &&
+ git status >output &&
test_cmp expect output
'
@@ -391,9 +393,9 @@ cat >expect <<EOF
# output
# untracked
EOF
-test_expect_success 'status submodule summary (--amend)' '
+test_expect_success 'commit --dry-run submodule summary (--amend)' '
git config status.submodulesummary 10 &&
- git status --amend >output &&
+ git commit --dry-run --amend >output &&
test_cmp expect output
'