test: fix name of AN

This commit is contained in:
moanos [he/him] 2024-11-12 22:39:07 +01:00
parent 03d40a5092
commit 93ae172431

View File

@ -1,6 +1,6 @@
from django.test import TestCase from django.test import TestCase
from fellchensammlung.forms import AdoptionNoticeFormWithDateWidgetAutoAnimal from fellchensammlung.forms import AdoptionNoticeFormWithDateWidgetAutoAnimal
from fellchensammlung.models import Animal, Species from fellchensammlung.models import Species
from model_bakery import baker from model_bakery import baker
@ -10,7 +10,7 @@ class TestAdoptionNoticeFormWithDateWidgetAutoAnimal(TestCase):
rat = baker.make(Species, name="Farbratte") rat = baker.make(Species, name="Farbratte")
def test_forms(self): def test_forms(self):
form_data = {"name": "Max + und + Moritz", form_data = {"name": "TestAdoption3",
"species": Species.objects.first(), "species": Species.objects.first(),
"num_animals": "2", "num_animals": "2",
"date_of_birth": "2024-11-04", "date_of_birth": "2024-11-04",
@ -22,6 +22,4 @@ class TestAdoptionNoticeFormWithDateWidgetAutoAnimal(TestCase):
"further_information": "https://notfellchen.org", "further_information": "https://notfellchen.org",
"save-and-add-another-animal": "Speichern"} "save-and-add-another-animal": "Speichern"}
form = AdoptionNoticeFormWithDateWidgetAutoAnimal(data=form_data) form = AdoptionNoticeFormWithDateWidgetAutoAnimal(data=form_data)
print(form.errors)
self.assertTrue(form.is_valid()) self.assertTrue(form.is_valid())