summaryrefslogtreecommitdiff
path: root/ishtar_common/tests.py
diff options
context:
space:
mode:
Diffstat (limited to 'ishtar_common/tests.py')
-rw-r--r--ishtar_common/tests.py6
1 files changed, 4 insertions, 2 deletions
diff --git a/ishtar_common/tests.py b/ishtar_common/tests.py
index 3c46ee6b2..565fdce2b 100644
--- a/ishtar_common/tests.py
+++ b/ishtar_common/tests.py
@@ -176,12 +176,14 @@ class MergeTest(TestCase):
self.author_1_pk = models.Author.objects.create(
person=self.person_1, author_type=self.author_types[0]).pk
+ self.title = models.TitleType.objects.create(label='Test')
+
self.company_2 = models.Organization.objects.create(
history_modifier=self.user, name='Goscinny Corp.',
organization_type=self.organisation_types[1])
self.person_2 = models.Person.objects.create(
name='Bill', history_modifier=self.user, surname='Peyo',
- title='Mr', attached_to=self.company_2)
+ title=self.title, attached_to=self.company_2)
self.person_2.person_types.add(self.person_types[1])
self.author_2_pk = models.Author.objects.create(
person=self.person_2, author_type=self.author_types[1]).pk
@@ -194,7 +196,7 @@ class MergeTest(TestCase):
# preserve existing fields
self.assertEqual(self.person_1.name, 'Boule')
# fill missing fields
- self.assertEqual(self.person_1.title, 'Mr')
+ self.assertEqual(self.person_1.title, self.title)
# string field with only spaces is an empty field
self.assertEqual(self.person_1.surname, 'Peyo')
# preserve existing foreign key