cp "$2" file &&
cp "$2" sub/dir/file &&
cp "$2" sub/dir/b/file &&
- cp "$2" objects/file
+ cp "$2" objects/file &&
+ test_might_fail git update-index --refresh -q
}
'
test_expect_success 'apply from .git dir' '
cp postimage expected &&
cp preimage .git/file &&
- cp preimage .git/objects/file
+ cp preimage .git/objects/file &&
(
cd .git &&
git apply "$patch"
test_cmp expected .git/file
'
-test_expect_failure 'apply from subdir of .git dir' '
+test_expect_success 'apply from subdir of .git dir' '
cp postimage expected &&
cp preimage .git/file &&
- cp preimage .git/objects/file
+ cp preimage .git/objects/file &&
(
cd .git/objects &&
git apply "$patch"