- Timestamp:
- 20 May 2012, 11:22:27 (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
main/waeup.fceokene/trunk/src/waeup/fceokene/students/tests/test_browser.py
r8460 r8475 113 113 ticket = createObject(u'waeup.CourseTicket') 114 114 verify.verifyObject(ICustomCourseTicket, ticket) 115 # Let's see if may_register works as expected 115 IWorkflowState(self.student).setState('returning') 116 # Let's see if next_session_allowed works as expected 116 117 # A, ug_ft, 100 117 self.assertTrue(self.student['studycourse']. may_register)118 self.assertTrue(self.student['studycourse'].next_session_allowed) 118 119 # O, ug_ft, 100 119 120 self.student['studycourse'].current_verdict = 'O' 120 self.assertTrue(self.student['studycourse']. may_register)121 self.assertTrue(self.student['studycourse'].next_session_allowed) 121 122 # O, ug_ft, 200 122 123 self.student['studycourse'].current_level = 200 123 self.assertFalse(self.student['studycourse']. may_register)124 self.assertFalse(self.student['studycourse'].next_session_allowed) 124 125 # O, de_ft, 200 125 126 self.student['studycourse'].certificate.study_mode = 'de_ft' 126 self.assertTrue(self.student['studycourse']. may_register)127 self.assertTrue(self.student['studycourse'].next_session_allowed) 127 128 # O, ph_ft, 300 128 129 self.student['studycourse'].certificate.study_mode = 'ph_ft' 129 130 self.student['studycourse'].current_level = 300 130 self.assertTrue(self.student['studycourse']. may_register)131 self.assertTrue(self.student['studycourse'].next_session_allowed) 131 132 # O, ph_ft, 400 132 133 self.student['studycourse'].current_level = 400 133 self.assertFalse(self.student['studycourse'].may_register) 134 self.assertFalse(self.student['studycourse'].next_session_allowed) 135 136 # Now we convert the certificate into a postgraduate certificate 137 IWorkflowState(self.student).setState('school fee paid') 138 self.certificate.study_mode = 'pg_ft' 139 # ... and voila next session registration is allowed 140 self.assertTrue(self.student['studycourse'].next_session_allowed) 134 141 135 142 def test_manage_access(self):
Note: See TracChangeset for help on using the changeset viewer.