title: Django reusable app url namespace issue
body: <p>I have a Django project, <code>training</code> and an app inside this project, <code>tests</code>. The folder structure looks like this:</p>
  
  <pre><code>django-training
      tests
          urls.py
      training
          urls.py
  </code></pre>
  
  <p>Inside <code>training/urls.py</code> I have this pattern defined:</p>
  
  <pre><code>url(r'^tests/', include('tests.urls', namespace='tests'))
  </code></pre>
  
  <p>And inside <code>tests/urls.py</code> I have these patterns defined:</p>
  
  <pre><code>url(r'^$', index, name='index'),
  url(r'^(\d+)/$', view, name='view'),
  url(r'^give-up/$', give_up, name='give_up'),
  url(r'^(\d+)/result/$', result, name='result')
  </code></pre>
  
  <p>Everything works fine.</p>
  
  <p>But, what if I want to package the <code>tests</code> app as a reusable app that works in any Django project? What should I do with the URL patterns?</p>
  
  <p>I created a <code>tests/settings.py</code> file and changed the <code>ROOT_URLCONF</code> config var to point to <code>tests/urls.py</code>. But this won't work, as this error will arise:</p>
  
  <pre><code>Traceback (most recent call last):
  File "/home/user/.virtualenvs/clean2/local/lib/python2.7/site-packages/tests/tests.py", line 173, in testContext
      response = self.client.get(reverse('tests:view', args=(1,)))
  File "/home/user/.virtualenvs/clean2/local/lib/python2.7/site-packages/django/core/urlresolvers.py", line 492, in reverse
  key)
  NoReverseMatch: u'tests' is not a registered namespace
  </code></pre>
  
  <p>The error is quite logic, since <code>reverse</code> needs the namespace to be defined (<code>tests</code>, that is).</p>
  
  <p>My question is: how and where shall I define this namespace for the reusable app so that URLs will work independent of the Django project the app is installed in?</p>