X-Git-Url: https://git.tokkee.org/?a=blobdiff_plain;f=t%2Ft0003-attributes.sh;h=51f3045ba4bde549b06ea669b1877f0e2db7c401;hb=55dcc2ebad1b3ed4a6912f6f401f63cd3c71026f;hp=dbb2623d930e433111f7e125749f5f1071e9ab3c;hpb=2e8722fc9e34a53ae19f2b60b1d3038aa2af0ae6;p=git.git diff --git a/t/t0003-attributes.sh b/t/t0003-attributes.sh index dbb2623d9..51f3045ba 100755 --- a/t/t0003-attributes.sh +++ b/t/t0003-attributes.sh @@ -159,6 +159,16 @@ test_expect_success 'relative paths' ' (cd b && attr_check ../a/b/g a/b/g) ' +test_expect_success 'prefixes are not confused with leading directories' ' + attr_check a_plus/g unspecified && + cat >expect <<-\EOF && + a/g: test: a/g + a_plus/g: test: unspecified + EOF + git check-attr test a/g a_plus/g >actual && + test_cmp expect actual +' + test_expect_success 'core.attributesfile' ' attr_check global unspecified && git config core.attributesfile "$HOME/global-gitattributes" &&