Skip to content

Commit a0ccd96

Browse files
committed
tests update
1 parent 6873a3a commit a0ccd96

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

tests/views/edit.py

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -244,18 +244,14 @@ def test_update_with_special_properties(self):
244244
['<Author: Randall Munroe (author of xkcd)>'])
245245

246246
def test_update_without_redirect(self):
247-
try:
247+
with self.assertRaises(ImproperlyConfigured):
248248
a = Author.objects.create(id='1',
249249
name='Randall Munroe',
250250
slug='randall-munroe', )
251251
self.client.post('/edit/author/%s/update/naive/' % a.pk, {
252252
'id': '1',
253253
'name': 'Randall Munroe (author of xkcd)',
254254
'slug': 'randall-munroe'})
255-
self.fail(
256-
'Should raise exception -- No redirect URL provided, and no get_absolute_url provided')
257-
except ImproperlyConfigured:
258-
pass
259255

260256
def test_update_get_object(self):
261257
a = Author.objects.create(pk='1',

0 commit comments

Comments
 (0)