Imported Upstream version 2.23.2
[platform/upstream/git.git] / t / t4010-diff-pathspec.sh
index 43c488b..281f8fa 100755 (executable)
@@ -74,12 +74,9 @@ test_expect_success 'diff-tree pathspec' '
        tree2=$(git write-tree) &&
        echo "$tree2" &&
        git diff-tree -r --name-only $tree $tree2 -- pa path1/a >current &&
-       >expected &&
-       test_cmp expected current
+       test_must_be_empty current
 '
 
-EMPTY_TREE=4b825dc642cb6eb9a060e54bf8d69288fbee4904
-
 test_expect_success 'diff-tree with wildcard shows dir also matches' '
        git diff-tree --name-only $EMPTY_TREE $tree -- "f*" >result &&
        echo file0 >expected &&
@@ -113,10 +110,10 @@ test_expect_success 'diff-tree -r with wildcard' '
 test_expect_success 'setup submodules' '
        test_tick &&
        git init submod &&
-       ( cd submod && test_commit first; ) &&
+       ( cd submod && test_commit first ) &&
        git add submod &&
        git commit -m first &&
-       ( cd submod && test_commit second; ) &&
+       ( cd submod && test_commit second ) &&
        git add submod &&
        git commit -m second
 '