From 824a20ffd09aae6e6de458f62978b8f4d25377a8 Mon Sep 17 00:00:00 2001 From: Bryce Kwon Date: Sat, 7 Nov 2026 12:00:22 -1000 Subject: Test the lowest message limit that cuts --- tests/t0103-log.sh | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/tests/t0103-log.sh b/tests/t0103-log.sh index 9309b10..cfd0998 100755 --- a/tests/t0103-log.sh +++ b/tests/t0103-log.sh @@ -223,6 +223,16 @@ test_expect_success 'a cut subject keeps whole characters' ' grep ">日本語の説\.\.\." tmp ' +test_expect_success 'a message limit below 15 turns the cut off' ' + git -C repos/foo commit --allow-empty -m "a subject well past fourteen bytes" && + cgitrc_copy cutrc max-message-length=15 && + cgit_ok cutrc "url=foo/log/" >tmp && + test_grep ">a subject we\.\.\." tmp && + cgitrc_copy nocutrc max-message-length=14 && + cgit_ok nocutrc "url=foo/log/" >tmp && + test_grep ">a subject well past fourteen bytes" tmp +' + test_expect_success 'the log draws the commit graph when enabled' ' cgitrc_copy graphrc enable-commit-graph=1 && cgit_ok graphrc "url=foo/log/" >tmp && -- cgit 2.12.1