From 09e47c4e5037152eebb897947126702779002087 Mon Sep 17 00:00:00 2001 From: Magdalena Noffke Date: Fri, 19 Aug 2016 14:49:48 +0200 Subject: [PATCH] fix test --- tests/reports/test_report_views.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/reports/test_report_views.py b/tests/reports/test_report_views.py index 60fc71e64..8480891dc 100644 --- a/tests/reports/test_report_views.py +++ b/tests/reports/test_report_views.py @@ -21,7 +21,7 @@ def test_anonymous_user_can_not_view_reportlist(apiclient): @pytest.mark.django_db -def test_authenticated_user_can_report(apiclient, user): +def test_authenticated_user_can_not_report_invalid_data(apiclient, user): apiclient.force_authenticate(user=user) url = reverse('reports-list') data = {} @@ -52,7 +52,7 @@ def test_authenticated_user_can_post(apiclient, user, comment, admin): assert response.status_code == status.HTTP_200_OK assert response.data['description'] == 'This comment sucks' assert len(mail.outbox) == 2 - assert 'A resource of type \'Comment\' has been reported' in mail.outbox[ + assert 'A Comment has been reported' in mail.outbox[ 0].subject assert 'A Comment that you created' in mail.outbox[ 1].subject