Reputation: 6394
In writing unit tests for Django, how would I test whether a particular view was used in rendering a URL? I was hoping there would exist TestCase.assertViewUsed, but I can't see it.
Thanks.
Upvotes: 0
Views: 62
Reputation: 42188
You can try to use django.core.urlresolvers.reverse
to create an url from view. This way you will see, whether view is mapped properly to an address.
Upvotes: 2