Merge branch 'jk/pager-with-external-command'
[gitweb.git] / t / t0003-attributes.sh
index 43957eae686203df6bda61a61fab791819b0804f..ae2f1da28fa55b92338d7dbcb6ef851b6ec40118 100755 (executable)
@@ -19,7 +19,7 @@ attr_check () {
 
 test_expect_success 'setup' '
 
-       mkdir -p a/b/d a/c &&
+       mkdir -p a/b/d a/c &&
        (
                echo "[attr]notest !test"
                echo "f test=f"
@@ -93,7 +93,7 @@ test_expect_success 'attribute test' '
 
 '
 
-test_expect_failure 'unnormalized paths' '
+test_expect_success 'unnormalized paths' '
 
        attr_check ./f f &&
        attr_check ./a/g a/g &&
@@ -102,6 +102,19 @@ test_expect_failure 'unnormalized paths' '
 
 '
 
+test_expect_success 'relative paths' '
+
+       (cd a && attr_check ../f f) &&
+       (cd a && attr_check f f) &&
+       (cd a && attr_check i a/i) &&
+       (cd a && attr_check g a/g) &&
+       (cd a && attr_check b/g a/b/g) &&
+       (cd b && attr_check ../a/f f) &&
+       (cd b && attr_check ../a/g a/g) &&
+       (cd b && attr_check ../a/b/g a/b/g)
+
+'
+
 test_expect_success 'core.attributesfile' '
        attr_check global unspecified &&
        git config core.attributesfile "$HOME/global-gitattributes" &&