comparison test/test_cgi.py @ 8590:db48c0bb4f1c

test: fix tokenless test use proper origin. The test I was using to test for Origin matching TRACKER_WEB was actually passing because it matched HTTP_HOST. Fix it so the test is correct.
author John Rouillard <rouilj@ieee.org>
date Mon, 20 Apr 2026 22:21:08 -0400
parents 4b2e885ecc07
children 501eb8088ea3
comparison
equal deleted inserted replaced
8589:4b2e885ecc07 8590:db48c0bb4f1c
1084 '?@ok_message=msg%20'), 1084 '?@ok_message=msg%20'),
1085 }, 1085 },
1086 { 1086 {
1087 # Case 2: POST should succeed with base origin. 1087 # Case 2: POST should succeed with base origin.
1088 "Request_Method": "POST", 1088 "Request_Method": "POST",
1089 "HTTP_Origin": "https://whoami.com", 1089 "HTTP_Origin": "http://tracker.example",
1090 "HTTP_Sec_Fetch_Site": None, 1090 "HTTP_Sec_Fetch_Site": None,
1091 "HTTP_Host": "whoami.com", 1091 "HTTP_Host": "whoami.com",
1092 "Result": ('Redirecting to ' 1092 "Result": ('Redirecting to '
1093 '<a href="http://whoami.com/path/issue1' 1093 '<a href="http://whoami.com/path/issue1'
1094 '?@ok_message=msg%20') 1094 '?@ok_message=msg%20')

Roundup Issue Tracker: http://roundup-tracker.org/