Changeset 11588 for main/waeup.kofa/trunk/src
- Timestamp:
- 22 Apr 2014, 05:43:05 (11 years ago)
- Location:
- main/waeup.kofa/trunk/src/waeup/kofa/students/tests
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
main/waeup.kofa/trunk/src/waeup/kofa/students/tests/test_browser.py
r11568 r11588 3027 3027 'Your personal data record is outdated.' in self.browser.contents) 3028 3028 3029 def test_setReturningData(self):3030 utils = getUtility(IStudentsUtils)3031 self.student['studycourse'].current_level = 6003032 utils.setReturningData(self.student)3033 # The new level exceeds the certificates end_level.3034 # In this case current_level remains unchanged and no error is raised.3035 self.assertEqual(self.student['studycourse'].current_level, 600)3036 3037 3029 def test_request_transcript(self): 3038 3030 IWorkflowState(self.student).setState('graduated') -
main/waeup.kofa/trunk/src/waeup/kofa/students/tests/test_utils.py
r9911 r11588 1 1 # -*- coding: utf-8 -*- 2 2 import unittest 3 from zope.component import getUtility 4 from waeup.kofa.students.interfaces import IStudentsUtils 3 5 from waeup.kofa.students.utils import formatted_text 6 from waeup.kofa.students.tests.test_browser import StudentsFullSetup 4 7 5 8 class FormatterTests(unittest.TestCase): … … 24 27 result5, u'<font color="red">sample</font>') 25 28 return 29 30 class StudentsUtilsTests(StudentsFullSetup): 31 32 def test_setReturningData(self): 33 utils = getUtility(IStudentsUtils) 34 self.student['studycourse'].current_level = 600 35 utils.setReturningData(self.student) 36 # The new level exceeds the certificates end_level. 37 # In this case current_level remains unchanged and no error is raised. 38 self.assertEqual(self.student['studycourse'].current_level, 600)
Note: See TracChangeset for help on using the changeset viewer.