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

« back to all changes in this revision

Viewing changes to t/t3010-ls-files-killed-modified.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-ls-files -k and -m flags test.
 
6
test_description='git ls-files -k and -m flags test.
7
7
 
8
8
This test prepares the following in the cache:
9
9
 
22
22
    path5       - a symlink
23
23
    path6/file6 - a file in a directory
24
24
 
25
 
git-ls-files -k should report that existing filesystem
 
25
git ls-files -k should report that existing filesystem
26
26
objects except path4, path5 and path6/file6 to be killed.
27
27
 
28
28
Also for modification test, the cache and working tree have:
47
47
: >path9
48
48
date >path10
49
49
test_expect_success \
50
 
    'git-update-index --add to add various paths.' \
51
 
    "git-update-index --add -- path0 path1 path?/file? path7 path8 path9 path10"
 
50
    'git update-index --add to add various paths.' \
 
51
    "git update-index --add -- path0 path1 path?/file? path7 path8 path9 path10"
52
52
 
53
53
rm -fr path? ;# leave path10 alone
54
54
date >path2
64
64
touch path10
65
65
 
66
66
test_expect_success \
67
 
    'git-ls-files -k to show killed files.' \
68
 
    'git-ls-files -k >.output'
 
67
    'git ls-files -k to show killed files.' \
 
68
    'git ls-files -k >.output'
69
69
cat >.expected <<EOF
70
70
path0/file0
71
71
path1/file1
74
74
EOF
75
75
 
76
76
test_expect_success \
77
 
    'validate git-ls-files -k output.' \
 
77
    'validate git ls-files -k output.' \
78
78
    'diff .output .expected'
79
79
 
80
80
test_expect_success \
81
 
    'git-ls-files -m to show modified files.' \
82
 
    'git-ls-files -m >.output'
 
81
    'git ls-files -m to show modified files.' \
 
82
    'git ls-files -m >.output'
83
83
cat >.expected <<EOF
84
84
path0
85
85
path1
90
90
EOF
91
91
 
92
92
test_expect_success \
93
 
    'validate git-ls-files -m output.' \
 
93
    'validate git ls-files -m output.' \
94
94
    'diff .output .expected'
95
95
 
96
96
test_done