aboutsummaryrefslogtreecommitdiff
path: root/t
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2009-05-03 15:01:26 -0700
committerJunio C Hamano <gitster@pobox.com>2009-05-03 15:01:26 -0700
commit3f3e2c26fa0325f4df952363f8f5046ca8158bb3 (patch)
treec1fd36e7ba69f1b24f38a47d7cae407b26abd899 /t
parent652f0c8f1df362755253fe9c5a975be7e5a5cbdc (diff)
parent150115aded2e1e0a83db7366f59e4b5bf1aa8135 (diff)
downloadgit-3f3e2c26fa0325f4df952363f8f5046ca8158bb3.tar.gz
git-3f3e2c26fa0325f4df952363f8f5046ca8158bb3.tar.xz
Merge branch 'jc/maint-1.6.0-diff-borrow-carefully' into maint-1.6.1
* jc/maint-1.6.0-diff-borrow-carefully: diff --cached: do not borrow from a work tree when a path is marked as assume-unchanged
Diffstat (limited to 't')
-rwxr-xr-xt/t4020-diff-external.sh8
1 files changed, 8 insertions, 0 deletions
diff --git a/t/t4020-diff-external.sh b/t/t4020-diff-external.sh
index caea292f1..2a72e751e 100755
--- a/t/t4020-diff-external.sh
+++ b/t/t4020-diff-external.sh
@@ -128,4 +128,12 @@ test_expect_success 'force diff with "diff"' '
test_cmp "$TEST_DIRECTORY"/t4020/diff.NUL actual
'
+test_expect_success 'diff --cached' '
+ git add file &&
+ git update-index --assume-unchanged file &&
+ echo second >file &&
+ git diff --cached >actual &&
+ test_cmp ../t4020/diff.NUL actual
+'
+
test_done