From 03fa846c6ab6abb7948ed6ecc84f35e7b6244b54 Mon Sep 17 00:00:00 2001 From: Alan Crosswell Date: Thu, 29 Aug 2019 13:15:46 -0400 Subject: Fixed #30731 -- Fixed handling trailing groups in simplify_regex(). Previously simplify_regex() didn't handle trailing groups for regexp without the end of string character ("$"). --- tests/admin_docs/test_views.py | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'tests/admin_docs') diff --git a/tests/admin_docs/test_views.py b/tests/admin_docs/test_views.py index 144517ab0a..fb021f3dd2 100644 --- a/tests/admin_docs/test_views.py +++ b/tests/admin_docs/test_views.py @@ -348,9 +348,13 @@ class AdminDocViewFunctionsTests(SimpleTestCase): (r'^a', '/a'), (r'^(?P\w+)/b/(?P\w+)/$', '//b//'), (r'^(?P\w+)/b/(?P\w+)$', '//b/'), + (r'^(?P\w+)/b/(?P\w+)', '//b/'), (r'^(?P\w+)/b/(\w+)$', '//b/'), + (r'^(?P\w+)/b/(\w+)', '//b/'), (r'^(?P\w+)/b/((x|y)\w+)$', '//b/'), + (r'^(?P\w+)/b/((x|y)\w+)', '//b/'), (r'^(?P(x|y))/b/(?P\w+)$', '//b/'), + (r'^(?P(x|y))/b/(?P\w+)', '//b/'), (r'^(?P(x|y))/b/(?P\w+)ab', '//b/ab'), (r'^(?P(x|y)(\(|\)))/b/(?P\w+)ab', '//b/ab'), (r'^a/?$', '/a/'), -- cgit v1.3