Mercurial > public > bravenewsurf
view bns_website/news/tests.py @ 41:9ce9f77d6cde
I added a get_absolute_url() to the news model so I can use that in the news template tag to create a link to the correct anchor on the news list page.
The link works, but for some reason it goes to the beginning of the article content and not to the title. I've played around with the article tag and making an aside tag with an id and for whatever reason it always goes to the article content.
author | Bob Mourlam <bob.mourlam@gmail.com> |
---|---|
date | Sun, 06 Nov 2011 22:13:27 -0600 |
parents | 2de51cc51d3a |
children | 66a3cafc4548 |
line wrap: on
line source
""" This file demonstrates writing tests using the unittest module. These will pass when you run "manage.py test". Replace this with more appropriate tests for your application. """ from django.test import TestCase class SimpleTest(TestCase): def test_basic_addition(self): """ Tests that 1 + 1 always equals 2. """ self.assertEqual(1 + 1, 2)