diff options
Diffstat (limited to 'tests')
| -rwxr-xr-x | tests/t0103-log.sh | 9 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
1 file changed, 9 insertions, 0 deletions
diff --git a/tests/t0103-log.sh b/tests/t0103-log.sh index 9671e7f..573baa8 100755 --- a/tests/t0103-log.sh +++ b/tests/t0103-log.sh @@ -110,4 +110,13 @@ test_expect_success 'the log draws the commit graph when enabled' ' grep "class=.commitgraph." tmp ' +# The search is literal, so text that is no valid regular expression still +# finds the commit holding it. +test_expect_success 'a search for brackets matches them literally' ' + git -C repos/foo commit --allow-empty -m "fix [brackets] in docs" && + cgit_url "foo/log&qt=grep&q=%5Bbrackets" >tmp && + grep "^Status: 200" tmp && + grep "fix \\[brackets\\] in docs" tmp +' + test_done |
