parts/django/tests/regressiontests/urlpatterns_reverse/included_urls2.py
changeset 307 c6bca38c1cbf
equal deleted inserted replaced
306:5ff1fc726848 307:c6bca38c1cbf
       
     1 """
       
     2 These URL patterns are included in two different ways in the main urls.py, with
       
     3 an extra argument present in one case. Thus, there are two different ways for
       
     4 each name to resolve and Django must distinguish the possibilities based on the
       
     5 argument list.
       
     6 """
       
     7 
       
     8 from django.conf.urls.defaults import *
       
     9 from views import empty_view
       
    10 
       
    11 urlpatterns = patterns('',
       
    12     url(r'^part/(?P<value>\w+)/$', empty_view, name="part"),
       
    13     url(r'^part2/(?:(?P<value>\w+)/)?$', empty_view, name="part2"),
       
    14 )