diff options
author | Jeff King <peff@peff.net> | 2015-12-01 17:21:17 -0500 |
---|---|---|
committer | Jeff King <peff@peff.net> | 2015-12-01 17:21:17 -0500 |
commit | 978b5760a11846ee7e2b928aca629a065a9d876d (patch) | |
tree | beb3e3a37ea7b596f184b18f108e0df6f0fc50bb /t | |
parent | 2cc36407df4eb919c4ad3da0561d1bbdb9e0c0c4 (diff) | |
parent | 4d2a3646d1f0285ce072cdfe34a7df64710f9357 (diff) | |
download | git-978b5760a11846ee7e2b928aca629a065a9d876d.tar.gz git-978b5760a11846ee7e2b928aca629a065a9d876d.tar.xz |
Merge branch 'sg/filter-branch-dwim-ambiguity' into maint
Fix for a corner case in filter-branch.
* sg/filter-branch-dwim-ambiguity:
filter-branch: deal with object name vs. pathname ambiguity in tree-filter
Diffstat (limited to 't')
-rwxr-xr-x | t/t7003-filter-branch.sh | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/t/t7003-filter-branch.sh b/t/t7003-filter-branch.sh index 377c648e0..869e0bf07 100755 --- a/t/t7003-filter-branch.sh +++ b/t/t7003-filter-branch.sh @@ -418,4 +418,11 @@ test_expect_success 'filter commit message without trailing newline' ' test_cmp expect actual ' +test_expect_success 'tree-filter deals with object name vs pathname ambiguity' ' + test_when_finished "git reset --hard original" && + ambiguous=$(git rev-list -1 HEAD) && + git filter-branch --tree-filter "mv file.t $ambiguous" HEAD^.. && + git show HEAD:$ambiguous +' + test_done |