From 6377dd5c95c221fd2aff008143a1e73c39ddb4c7 Mon Sep 17 00:00:00 2001 From: Ludovic Stephan Date: Tue, 15 Sep 2020 11:49:18 +0200 Subject: [PATCH] BdA : tests --- bda/tests/mixins.py | 10 ---------- bda/tests/test_models.py | 2 -- bda/tests/test_views.py | 1 - 3 files changed, 13 deletions(-) diff --git a/bda/tests/mixins.py b/bda/tests/mixins.py index a4ba057b..1f690172 100644 --- a/bda/tests/mixins.py +++ b/bda/tests/mixins.py @@ -1,7 +1,3 @@ -import os - -from django.conf import settings -from django.core.management import call_command from django.utils import timezone from shared.tests.mixins import ViewTestCaseMixin @@ -28,12 +24,6 @@ class BdATestHelpers: if self.bda_testdata: self.load_bda_testdata() - def require_custommails(self): - data_file = os.path.join( - settings.BASE_DIR, "gestioncof", "management", "data", "custommail.json" - ) - call_command("syncmails", data_file, verbosity=0) - def load_bda_testdata(self): self.tirage = Tirage.objects.create( title="Test tirage", diff --git a/bda/tests/test_models.py b/bda/tests/test_models.py index ba96238a..abff407b 100644 --- a/bda/tests/test_models.py +++ b/bda/tests/test_models.py @@ -19,8 +19,6 @@ User = get_user_model() class SpectacleReventeTests(TestCase): - fixtures = ["gestioncof/management/data/custommail.json"] - def setUp(self): now = timezone.now() diff --git a/bda/tests/test_views.py b/bda/tests/test_views.py index b223203f..75d01ec9 100644 --- a/bda/tests/test_views.py +++ b/bda/tests/test_views.py @@ -279,7 +279,6 @@ class SendRemindersViewTestCase(BdATestHelpers, BdAViewTestCaseMixin, TestCase): return "/gestion/bda/mails-rappel/{}".format(self.show1.id) def test_post(self): - self.require_custommails() resp = self.client.post(self.url) self.assertEqual(200, resp.status_code) # TODO: check that emails are sent