From 8bd6e4fb2d0519f4685e67e2478262d4f6eed19d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jes=C3=BAs=20Espino?= Date: Mon, 18 Aug 2014 12:48:32 +0200 Subject: [PATCH] Fixed proyect notification policy tests --- tests/integration/test_project_notifications.py | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/tests/integration/test_project_notifications.py b/tests/integration/test_project_notifications.py index 5b5c9412..af572dba 100644 --- a/tests/integration/test_project_notifications.py +++ b/tests/integration/test_project_notifications.py @@ -102,9 +102,11 @@ def test_users_to_notify(): member2 = f.MembershipFactory.create(project=project) member3 = f.MembershipFactory.create(project=project) - policy1 = services.create_notify_policy(project, member1.user) - policy2 = services.create_notify_policy(project, member2.user) - policy3 = services.create_notify_policy(project, member3.user) + policy_model_cls = get_model("notifications", "NotifyPolicy") + + policy1 = policy_model_cls.objects.get(user=member1.user) + policy2 = policy_model_cls.objects.get(user=member2.user) + policy3 = policy_model_cls.objects.get(user=member3.user) history = MagicMock() history.owner = member2.user