Changeset 10178 for main/waeup.kofa/trunk/src/waeup/kofa/students/tests
- Timestamp:
- 15 May 2013, 06:47:52 (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
main/waeup.kofa/trunk/src/waeup/kofa/students/tests/test_browser.py
r10060 r10178 1811 1811 'temp_password generated: %s' % temp_password in logcontent) 1812 1812 1813 def test_transcrtipts(self): 1814 studylevel = createObject(u'waeup.StudentStudyLevel') 1815 studylevel.level = 100 1816 studylevel.level_session = 2005 1817 self.student['studycourse'].addStudentStudyLevel( 1818 self.certificate, studylevel) 1819 # Add second course 1820 courseticket = createObject('waeup.CourseTicket') 1821 courseticket.code = 'ANYCODE' 1822 courseticket.title = u'Any TITLE' 1823 courseticket.credits = 13 1824 courseticket.score = 66 1825 courseticket.semester = 1 1826 courseticket.dcode = u'ANYDCODE' 1827 courseticket.fcode = u'ANYFCODE' 1828 self.student['studycourse']['100']['COURSE2'] = courseticket 1829 self.student['studycourse']['100']['COURSE1'].score = 55 1830 self.assertEqual(self.student['studycourse']['100'].gpa, 3.57) 1831 # Get transcript data 1832 td = self.student['studycourse'].getTranscriptData() 1833 self.assertEqual(td[0][0]['level_key'], '100') 1834 self.assertEqual(td[0][0]['level'].level, 100) 1835 self.assertEqual(td[0][0]['level'].level_session, 2005) 1836 self.assertEqual(td[0][0]['tickets_1'][0].code, 'COURSE1') 1837 self.assertEqual(td[0][0]['tickets_1'][1].code, 'ANYCODE') 1838 self.assertEqual(td[1], 3.57) 1839 self.browser.addHeader('Authorization', 'Basic mgr:mgrpw') 1840 self.browser.open(self.student_path + '/studycourse/transcript') 1841 self.assertEqual(self.browser.headers['Status'], '200 Ok') 1842 self.assertTrue('Transcript' in self.browser.contents) 1843 1813 1844 class StudentUITests(StudentsFullSetup): 1814 1845 # Tests for Student class views and pages
Note: See TracChangeset for help on using the changeset viewer.