Skip to content

Commit

Permalink
Failing test for incorrect template Session property
Browse files Browse the repository at this point in the history
  • Loading branch information
Bouke committed Apr 11, 2017
1 parent ece45f3 commit dbf4102
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion tests/tests.py
Original file line number Diff line number Diff line change
Expand Up @@ -86,9 +86,13 @@ def setUp(self):
assert self.client.login(username='bouke', password='secret')

def test_list(self):
self.user.session_set.create(session_key='ABC123', ip='127.0.0.1',
expire_date=datetime.now() + timedelta(days=1),
user_agent='Firefox')
response = self.client.get(reverse('user_sessions:session_list'))
self.assertContains(response, 'Active Sessions')
self.assertContains(response, 'End Session', 2)
self.assertContains(response, 'End Session', 3)
self.assertContains(response, 'Firefox')

def test_delete(self):
session_key = self.client.cookies[settings.SESSION_COOKIE_NAME].value
Expand Down

0 comments on commit dbf4102

Please sign in to comment.