Fix problem with missing names

- Legacy-Id: 17127
This commit is contained in:
Ole Laursen 2019-12-06 19:56:03 +00:00
parent defc50caf5
commit 6920c179cd

View file

@ -20,6 +20,7 @@ from ietf.group import colors
from ietf.meeting.factories import SessionFactory
from ietf.meeting.test_data import make_meeting_test_data
from ietf.meeting.models import SchedTimeSessAssignment
from ietf.name.models import SessionStatusName
from ietf.utils.test_runner import set_coverage_checking
from ietf.utils.pipe import pipe
from ietf import settings
@ -118,7 +119,11 @@ class SlideReorderTests(StaticLiveServerTestCase):
def setUp(self):
self.driver = webdriver.PhantomJS(port=0, service_log_path=settings.TEST_GHOSTDRIVER_LOG_PATH)
self.driver.set_window_size(1024,768)
self.session = SessionFactory(meeting__type_id='ietf')
# this is a temporary fix - we should have these name in the
# database already at this point
SessionStatusName.objects.get_or_create(slug='schedw')
SessionStatusName.objects.get_or_create(slug='sched')
self.session = SessionFactory(meeting__type_id='ietf', status_id='sched')
self.session.sessionpresentation_set.create(document=DocumentFactory(type_id='slides',name='one'),order=1)
self.session.sessionpresentation_set.create(document=DocumentFactory(type_id='slides',name='two'),order=2)
self.session.sessionpresentation_set.create(document=DocumentFactory(type_id='slides',name='three'),order=3)