3 test_description
=gitattributes
12 git check-attr
test -- "$path" >actual
&&
13 echo "$path: test: $2" >expect
&&
14 test_cmp expect actual
19 test_expect_success
'setup' '
29 ) >a/.gitattributes &&
31 echo "h test=a/b/h" &&
32 echo "d/* test=a/b/d/*"
37 test_expect_success
'attribute test' '
43 attr_check a/b/g a/b/g &&
44 attr_check b/g unspecified &&
45 attr_check a/b/h a/b/h &&
46 attr_check a/b/d/g "a/b/d/*"
50 test_expect_success
'root subdir attribute test' '
53 attr_check subdir/a/i unspecified
57 test_expect_success
'setup bare' '
59 git clone --bare . bare.git &&
64 test_expect_success
'bare repository: check that .gitattribute is ignored' '
70 attr_check f unspecified &&
71 attr_check a/f unspecified &&
72 attr_check a/c/f unspecified &&
73 attr_check a/i unspecified &&
74 attr_check subdir/a/i unspecified
78 test_expect_success
'bare repository: test info/attributes' '
88 attr_check subdir/a/i unspecified