title: Django url unit test comparison of expected view function fails
body: <pre><code>class TestsUrls(SimpleTestCase):
  
  def test_index_url_is_resolved(self):
      url = reverse('index')
      self.assertEquals(resolve(url).func, index)
  </code></pre>
  
  <p>I am trying to unit test url to see if it returns the expected view. This assertion fails even though it looks like the functions are the same. I am using function based views, not class based views. Does that have something to do with it?</p>
  
  <pre><code>AssertionError: &lt;function index at 0x11db7cb70&gt; != &lt;function index at 0x11d860ae8&gt;
  </code></pre>