- Timestamp:
- 20 Sep 2012, 08:22:52 (12 years ago)
- Location:
- main/waeup.kofa/branches/uli-async-update
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
main/waeup.kofa/branches/uli-async-update
- Property svn:mergeinfo changed
/main/waeup.kofa/trunk merged: 9172,9178,9180,9182-9184,9186-9189,9191-9204
- Property svn:mergeinfo changed
-
main/waeup.kofa/branches/uli-async-update/src/waeup/kofa/students/tests/test_browser.py
r9169 r9208 403 403 404 404 layer = FunctionalLayer 405 406 def test_student_properties(self): 407 self.student['studycourse'].current_level = 100 408 self.assertEqual(self.student.current_level, 100) 409 self.student['studycourse'].current_session = 2011 410 self.assertEqual(self.student.current_session, 2011) 411 self.student['studycourse'].current_verdict = 'A' 412 self.assertEqual(self.student.current_verdict, 'A') 413 return 405 414 406 415 def test_basic_auth(self): … … 1183 1192 self.assertTrue( 1184 1193 'You logged in.' in self.browser.contents) 1185 # Student can upload a passport picture1194 # Admitted student can upload a passport picture 1186 1195 self.browser.open(self.student_path + '/change_portrait') 1187 1196 ctrl = self.browser.getControl(name='passportuploadedit') … … 1194 1203 '<img align="middle" height="125px" src="passport.jpg" />' 1195 1204 in self.browser.contents) 1205 # Students can open admission letter 1206 self.browser.getLink("Base Data").click() 1207 self.browser.getLink("Download admission letter").click() 1208 self.assertEqual(self.browser.headers['Status'], '200 Ok') 1209 self.assertEqual(self.browser.headers['Content-Type'], 'application/pdf') 1196 1210 # Student can view the clearance data 1211 self.browser.open(self.student_path) 1197 1212 self.browser.getLink("Clearance Data").click() 1198 1213 # Student can't open clearance edit form before starting clearance … … 1584 1599 1585 1600 def test_student_previous_payments(self): 1601 configuration = createObject('waeup.SessionConfiguration') 1602 configuration.academic_session = 2000 1603 configuration.clearance_fee = 3456.0 1604 configuration.booking_fee = 123.4 1605 self.student['studycourse'].entry_session = 2002 1606 self.app['configuration'].addSessionConfiguration(configuration) 1607 configuration2 = createObject('waeup.SessionConfiguration') 1608 configuration2.academic_session = 2003 1609 configuration2.clearance_fee = 3456.0 1610 configuration2.booking_fee = 123.4 1611 self.student['studycourse'].entry_session = 2002 1612 self.app['configuration'].addSessionConfiguration(configuration2) 1586 1613 # Login 1587 1614 self.browser.open(self.login_path) … … 1606 1633 # Previous session payment form is provided 1607 1634 self.browser.getControl(name="form.p_category").value = ['schoolfee'] 1635 self.browser.getControl(name="form.p_session").value = ['2000'] 1636 self.browser.getControl(name="form.p_level").value = ['300'] 1637 self.browser.getControl("Create ticket").click() 1638 self.assertMatches('...The previous session must not fall below...', 1639 self.browser.contents) 1640 self.browser.getControl(name="form.p_category").value = ['schoolfee'] 1608 1641 self.browser.getControl(name="form.p_session").value = ['2004'] 1642 self.browser.getControl(name="form.p_level").value = ['300'] 1643 self.browser.getControl("Create ticket").click() 1644 self.assertMatches('...This is not a previous session...', 1645 self.browser.contents) 1646 self.browser.getControl(name="form.p_category").value = ['schoolfee'] 1647 self.browser.getControl(name="form.p_session").value = ['2003'] 1609 1648 self.browser.getControl(name="form.p_level").value = ['300'] 1610 1649 self.browser.getControl("Create ticket").click() … … 1619 1658 1620 1659 # Payment session is properly set 1621 self.assertEqual(self.student['payments'][value].p_session, 200 4)1660 self.assertEqual(self.student['payments'][value].p_session, 2003) 1622 1661 self.assertEqual(self.student['payments'][value].p_level, 300) 1623 1662 … … 1954 1993 self.browser.getControl(name="form.identifier").value = '123' 1955 1994 self.browser.getControl(name="form.email").value = 'aa@aa.ng' 1956 self.browser.getControl(" Getlogin credentials").click()1995 self.browser.getControl("Send login credentials").click() 1957 1996 self.assertTrue('An email with' in self.browser.contents) 1958 1997
Note: See TracChangeset for help on using the changeset viewer.