3
3
# Copyright (c) 2005 Junio C Hamano
6
test_description='git-checkout-index -u test.
6
test_description='git checkout-index -u test.
8
With -u flag, git-checkout-index internally runs the equivalent of
9
git-update-index --refresh on the checked out entry.'
8
With -u flag, git checkout-index internally runs the equivalent of
9
git update-index --refresh on the checked out entry.'
13
13
test_expect_success \
15
15
echo frotz >path0 &&
16
git-update-index --add path0 &&
16
git update-index --add path0 &&
19
19
test_expect_failure \
20
'without -u, git-checkout-index smudges stat information.' '
20
'without -u, git checkout-index smudges stat information.' '
23
git-checkout-index -f -a &&
24
git-diff-files | diff - /dev/null'
23
git checkout-index -f -a &&
24
git diff-files | diff - /dev/null'
26
26
test_expect_success \
27
'with -u, git-checkout-index picks up stat information from new files.' '
27
'with -u, git checkout-index picks up stat information from new files.' '
30
git-checkout-index -u -f -a &&
31
git-diff-files | diff - /dev/null'
30
git checkout-index -u -f -a &&
31
git diff-files | diff - /dev/null'