~ubuntu-branches/ubuntu/intrepid/git-core/intrepid-security

« back to all changes in this revision

Viewing changes to t/t2002-checkout-cache-u.sh

  • Committer: Package Import Robot
  • Author(s): Gerrit Pape
  • Date: 2007-10-04 08:27:01 UTC
  • mfrom: (1.1.23)
  • Revision ID: package-import@ubuntu.com-20071004082701-rsd058ontoqz4i30
Tags: 1:1.5.3.4-1
new upstream point release (closes: #445188).

Show diffs side-by-side

added added

removed removed

Lines of Context:
3
3
# Copyright (c) 2005 Junio C Hamano
4
4
#
5
5
 
6
 
test_description='git-checkout-index -u test.
 
6
test_description='git checkout-index -u test.
7
7
 
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.'
10
10
 
11
11
. ./test-lib.sh
12
12
 
13
13
test_expect_success \
14
14
'preparation' '
15
15
echo frotz >path0 &&
16
 
git-update-index --add path0 &&
17
 
t=$(git-write-tree)'
 
16
git update-index --add path0 &&
 
17
t=$(git write-tree)'
18
18
 
19
19
test_expect_failure \
20
 
'without -u, git-checkout-index smudges stat information.' '
 
20
'without -u, git checkout-index smudges stat information.' '
21
21
rm -f path0 &&
22
 
git-read-tree $t &&
23
 
git-checkout-index -f -a &&
24
 
git-diff-files | diff - /dev/null'
 
22
git read-tree $t &&
 
23
git checkout-index -f -a &&
 
24
git diff-files | diff - /dev/null'
25
25
 
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.' '
28
28
rm -f path0 &&
29
 
git-read-tree $t &&
30
 
git-checkout-index -u -f -a &&
31
 
git-diff-files | diff - /dev/null'
 
29
git read-tree $t &&
 
30
git checkout-index -u -f -a &&
 
31
git diff-files | diff - /dev/null'
32
32
 
33
33
test_done