2
0
mirror of https://expo.survex.com/repositories/troggle/.git synced 2026-02-08 14:28:09 +00:00

testsuite passes - Area removed

This commit is contained in:
2023-09-10 15:55:01 +03:00
parent ab79a43afa
commit 2f6017d6d3
4 changed files with 7 additions and 62 deletions

View File

@@ -7,7 +7,7 @@ from http import HTTPStatus
from django.test import Client, TestCase
from troggle.core.models.caves import Area, Cave
from troggle.core.models.caves import Cave
from troggle.core.models.troggle import Person, PersonExpedition
# import troggle.settings as settings
@@ -18,7 +18,7 @@ class FixtureTests(TestCase):
They do not exercise the GET and url functions
"""
fixtures = ["auth_users", "expo_areas", "expo_caves", "expo_exped"]
fixtures = ["auth_users", "expo_caves", "expo_exped"]
ph = r"and leads in 800m of tortuous going to"
def setUp(self):
@@ -36,15 +36,12 @@ class FixtureTests(TestCase):
self.assertEqual(str(pe.person.fullname), "Michael Sargent")
self.assertEqual(str(pe.expedition.year), "2019")
def test_fix_area_loaded(self):
a = Area.objects.get(short_name="1623")
self.assertEqual(str(a.short_name), "1623")
def test_fix_cave_loaded115(self):
c = Cave.objects.get(kataster_number="115")
self.assertEqual(str(c.description_file), "1623/115.htm")
self.assertEqual(str(c.url), "1623/115.url") # intentional
self.assertEqual(str(c.filename), "1623-115.html")
self.assertEqual(str(c.areacode), "1623")
# c.area is a 'ManyRelatedManager' object and not iterable
# self.assertEqual(str(c.[0].short_name), "1623")
@@ -82,7 +79,7 @@ class FixturePageTests(TestCase):
"""
# The fixtures have a password hash which is compatible with plain-text password 'secretword'
fixtures = ["auth_users", "expo_areas", "expo_caves", "expo_exped"]
fixtures = ["auth_users", "expo_caves", "expo_exped"]
ph = r"and leads in 800m of tortuous going to"
@classmethod