mirror of
https://github.com/django/django.git
synced 2025-10-24 06:06:09 +00:00
Added an explicit test that URL checks are recursive.
This commit is contained in:
committed by
Tim Graham
parent
86573861a9
commit
ffb1c532ec
@@ -10,6 +10,14 @@ class CheckUrlsTest(SimpleTestCase):
|
||||
result = check_url_config(None)
|
||||
self.assertEqual(result, [])
|
||||
|
||||
@override_settings(ROOT_URLCONF='check_framework.urls.warning_in_include')
|
||||
def test_check_resolver_recursive(self):
|
||||
# The resolver is checked recursively (examining url()s in include()).
|
||||
result = check_url_config(None)
|
||||
self.assertEqual(len(result), 1)
|
||||
warning = result[0]
|
||||
self.assertEqual(warning.id, 'urls.W001')
|
||||
|
||||
@override_settings(ROOT_URLCONF='check_framework.urls.include_with_dollar')
|
||||
def test_include_with_dollar(self):
|
||||
result = check_url_config(None)
|
||||
|
||||
Reference in New Issue
Block a user