diff options
author | Junio C Hamano <gitster@pobox.com> | 2018-11-13 13:37:28 (GMT) |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2018-11-13 13:37:28 (GMT) |
commit | 1e4a714e689e14726982941d8e61db06c6c7d58d (patch) | |
tree | a88cee0ddc58c7399b9e7d56c9e96ff5e96c9865 /t | |
parent | 57f06d5ab5b615e9e529ba1e42e835468a7765e6 (diff) | |
parent | b7845cebc02a7224ee34d1b90a5c11370daf1924 (diff) | |
download | git-1e4a714e689e14726982941d8e61db06c6c7d58d.zip git-1e4a714e689e14726982941d8e61db06c6c7d58d.tar.gz git-1e4a714e689e14726982941d8e61db06c6c7d58d.tar.bz2 |
Merge branch 'nd/tree-walk-path-exclusion'
Pathspec matching against a tree object were buggy when negative
pathspec elements were involved, which has been fixed.
* nd/tree-walk-path-exclusion:
tree-walk.c: fix overoptimistic inclusion in :(exclude) matching
Diffstat (limited to 't')
-rwxr-xr-x | t/t6132-pathspec-exclude.sh | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/t/t6132-pathspec-exclude.sh b/t/t6132-pathspec-exclude.sh index eb829fc..2462b19 100755 --- a/t/t6132-pathspec-exclude.sh +++ b/t/t6132-pathspec-exclude.sh @@ -194,4 +194,21 @@ test_expect_success 'multiple exclusions' ' test_cmp expect actual ' +test_expect_success 't_e_i() exclude case #8' ' + git init case8 && + ( + cd case8 && + echo file >file1 && + echo file >file2 && + git add file1 file2 && + git commit -m twofiles && + git grep -l file HEAD :^file2 >actual && + echo HEAD:file1 >expected && + test_cmp expected actual && + git grep -l file HEAD :^file1 >actual && + echo HEAD:file2 >expected && + test_cmp expected actual + ) +' + test_done |