Diff options
| author | Bryce Kwon <bryce@brycekwon.com> | |
|---|---|---|
| committer | Bryce Kwon <bryce@brycekwon.com> | |
| commit | ||
| parent | ||
| tree | ||
| download | ||
Offer no diff options on an octopus merge
The commit page draws no diff for a merge of three or more parents, so
the options above it changed nothing.
Diffstat (limited to '')
| -rwxr-xr-x | tests/t0106-commit.sh | 12 |
1 file changed, 12 insertions, 0 deletions
diff --git a/tests/t0106-commit.sh b/tests/t0106-commit.sh index 7de0a76..5564038 100755 --- a/tests/t0106-commit.sh +++ b/tests/t0106-commit.sh @@ -72,4 +72,16 @@ test_expect_success 'a message that is not UTF-8 has its stray bytes replaced' ' ! grep "caf$(printf "\351")" tmp ' +test_expect_success 'an octopus merge, which draws no diff, offers no diff options' ' + ( + cd repos/foo && + cid=$(git commit-tree -p HEAD -p HEAD~1 -p HEAD~2 -m octopus HEAD^{tree}) && + git update-ref refs/heads/octopus "$cid" + ) && + cgit_query "url=foo/commit&h=octopus" >tmp && + ! grep "cgit-panel" tmp && + cgit_query "url=foo/commit" >tmp && + grep "cgit-panel" tmp +' + test_done |
