Hi everyone,

I'm having a problem with reversing a URL in a unit test:


class ProductTestCase(TestCase):
    def setUp(self):
        self.client = Client

    def test_project_permalink(self):
        project = Project.approved.all()[0]
        url = project.get_absolute_url()


I'm using an initial_data.json fixture that I exported from my current
database, and I'm able to use the get_absolute_url method to navigate
to a project detail page without error.

When I try to reverse this url pattern in a test, I get a
NoReverseMatch exception. django-cms is also running on my site, but
disabling that app, and its url patterns doesn't make a difference.

Anyone have any ideas on why this method would fail?

TIA,
Brandon

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.

Reply via email to