Fixed #21157 -- Fixed problems with ResolverMatch

- Fixed bug in get_callable() that caused resolve() to put a string
  in ResolverMatch.func.
- Made ResolverMatch.url_name match the actual url name (or None).
- Updated tests that used the string value in ResolverMatch.func, and
  added regression tests for this bug.
- Corrected test urls whose dummy view paths caused failures (behavior
  that was previously masked by this bug).
This commit is contained in:
Kevin Christopher Henry 2013-10-03 03:20:04 -04:00 committed by Tim Graham
parent 0aa4c6c391
commit 91afc00513
10 changed files with 121 additions and 93 deletions

View file

@ -1,7 +1,7 @@
from django.conf.urls import url
urlpatterns = [
url(r'^noslash$', 'view'),
url(r'^slash/$', 'view'),
url(r'^needsquoting#/$', 'view'),
url(r'^noslash$', 'middleware.views.empty_view'),
url(r'^slash/$', 'middleware.views.empty_view'),
url(r'^needsquoting#/$', 'middleware.views.empty_view'),
]