From 156e1b7c3f8a7a2098d1a1510571a447e3cea18d Mon Sep 17 00:00:00 2001 From: Bryce Kwon Date: Sat, 7 Nov 2026 16:14:56 -1000 Subject: Ask for the two 404 pages with the cache off Both requests went through the shared page cache, and the clone one only worked because clone pages are never stored, which is what the cgitrc_copy comment warns of. --- tests/t0301-security.sh | 19 +++++++++---------- 1 file changed, 9 insertions(+), 10 deletions(-) (limited to 'tests') diff --git a/tests/t0301-security.sh b/tests/t0301-security.sh index 4bb187e..9b887d4 100755 --- a/tests/t0301-security.sh +++ b/tests/t0301-security.sh @@ -290,20 +290,19 @@ test_expect_success 'a doubled percent in a module-link renders as one' ' # An unknown page under a repository used to reach the page header with no # head resolved and crash in the branch switcher. test_expect_success 'an unknown page under a repository answers 404 with its header' ' - cgit_url "foo/nonsense/" >tmp && - grep "^Status: 404 Not Found" tmp && - grep "Invalid request" tmp && - grep "noclonerc && + cgitrc_copy noclonerc enable-http-clone=0 && cgit_rc noclonerc "url=foo/info/refs" >tmp && - grep "^Status: 404 Not Found" tmp && - grep "