Unverified Commit c90dcd33 authored by Joost Rijneveld's avatar Joost Rijneveld
Browse files

activemembers/board: test if absolute_url reverses

parent e5e1b135
......@@ -26,5 +26,24 @@
"photo": "Thom_Wiggers_4YRoxV3.jpg",
"permissions": []
}
},
{
"model": "activemembers.committee",
"pk": 3,
"fields": {
"name_nl": "testbestuur1",
"name_en": "testboard1",
"description_nl": "testdesc1",
"description_en": "testdesc1",
"since": "1990-09-01",
"until": "1991-09-01"
}
},
{
"model": "activemembers.board",
"pk": 3,
"fields": {
"is_board": true
}
}
]
......@@ -4,7 +4,7 @@ from django.db.utils import IntegrityError
from django.test import TestCase
from django.utils import timezone
from activemembers.models import Committee, CommitteeMembership
from activemembers.models import Committee, CommitteeMembership, Board
from members.models import Member
......@@ -144,3 +144,13 @@ class PermissionsBackendTest(TestCase):
def test_nonmember_user(self):
u = get_user_model().objects.create(username='foo')
self.assertEqual(set(), u.get_all_permissions())
class BoardTest(TestCase):
fixtures = ['committees.json']
def setUp(self):
self.testboard = Board.objects.get(pk=3)
def test_get_absolute_url(self):
self.testboard.get_absolute_url()
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment