Changeset 15998 for main/waeup.kofa/trunk/src/waeup/kofa/students/tests
- Timestamp:
- 11 Feb 2020, 07:26:29 (5 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
main/waeup.kofa/trunk/src/waeup/kofa/students/tests/test_browser.py
r15986 r15998 2375 2375 in self.browser.contents) 2376 2376 2377 def test_update_coursetickets(self): 2378 IWorkflowState(self.student).setState('school fee paid') 2379 studylevel = createObject(u'waeup.StudentStudyLevel') 2380 studylevel.level = 100 2381 studylevel.level_session = 2015 2382 self.student['studycourse'].entry_mode = 'ug_ft' 2383 self.student['studycourse'].addStudentStudyLevel( 2384 self.certificate, studylevel) 2385 self.browser.addHeader('Authorization', 'Basic mgr:mgrpw') 2386 self.browser.open( 2387 'http://localhost/app/faculties/fac1/dep1/courses/COURSE1/') 2388 self.assertFalse( 2389 'Update session 2015/2016 credits' in self.browser.contents) 2390 self.app['configuration'].current_academic_session = 2015 2391 self.browser.open( 2392 'http://localhost/app/faculties/fac1/dep1/courses/COURSE1/') 2393 self.browser.getLink("Update session 2015/2016 credits").click() 2394 self.assertTrue( 2395 'No course ticket found.' in self.browser.contents) 2396 logfile = os.path.join( 2397 self.app['datacenter'].storage, 'logs', 'main.log') 2398 logcontent = open(logfile).read() 2399 self.assertTrue( 2400 'zope.mgr - browser.pages.UpdateCourseTicketsView - ' 2401 'course tickets updated: COURSE1' in logcontent) 2402 studylevel['COURSE1'].credits = 12 2403 self.browser.getLink("Update session 2015/2016 credits").click() 2404 self.assertTrue( 2405 'No course ticket found.' in self.browser.contents) 2406 studylevel.level_session = 2015 2407 self.student['studycourse'].current_session = 2015 2408 self.browser.getLink("Update session 2015/2016 credits").click() 2409 self.assertTrue( 2410 '1 course ticket(s) updated.' in self.browser.contents) 2411 logfile = os.path.join( 2412 self.app['datacenter'].storage, 'logs', 'students.log') 2413 logcontent = open(logfile).read() 2414 self.assertTrue( 2415 'zope.mgr - students.utils.StudentsUtils - ' 2416 'K1000000 100/COURSE1 credits updated (10->12)' in logcontent) 2417 return 2418 2377 2419 2378 2420 class StudentUITests(StudentsFullSetup):
Note: See TracChangeset for help on using the changeset viewer.