Changeset 6818 for main/waeup.sirp/trunk/src/waeup/sirp/students/tests
- Timestamp:
- 27 Sep 2011, 08:00:33 (13 years ago)
- Location:
- main/waeup.sirp/trunk/src/waeup/sirp/students/tests
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
main/waeup.sirp/trunk/src/waeup/sirp/students/tests/test_authentication.py
r6756 r6818 65 65 class FakeStudent(object): 66 66 student_id = 'test_stud' 67 name = 'Test User'67 fullname = 'Test User' 68 68 password = None 69 69 -
main/waeup.sirp/trunk/src/waeup/sirp/students/tests/test_browser.py
r6810 r6818 69 69 setSite(app) 70 70 71 # Add student with subobjects (done by addStudent)71 # Add student with subobjects 72 72 student = Student() 73 student. name = u'Anna Tester'73 student.fullname = u'Anna Tester' 74 74 student.reg_number = u'123' 75 75 student.matric_number = u'234' … … 186 186 self.assertEqual(self.browser.headers['Status'], '200 Ok') 187 187 self.assertEqual(self.browser.url, self.add_student_path) 188 self.browser.getControl(name="form. name").value = 'Bob Tester'188 self.browser.getControl(name="form.fullname").value = 'Bob Tester' 189 189 self.browser.getControl("Create student record").click() 190 190 self.assertTrue('Student record created' in self.browser.contents) … … 213 213 self.browser.getControl("Search").click() 214 214 self.assertTrue('Empty search string' in self.browser.contents) 215 self.browser.getControl(name="searchtype").value = [' name']215 self.browser.getControl(name="searchtype").value = ['fullname'] 216 216 self.browser.getControl(name="searchterm").value = 'Anna Tester' 217 217 self.browser.getControl("Search").click() … … 255 255 # Managers can edit base data and fire transitions 256 256 self.browser.getControl(name="transition").value = ['admit'] 257 self.browser.getControl(name="form. name").value = 'John Tester'257 self.browser.getControl(name="form.fullname").value = 'John Tester' 258 258 self.browser.getControl(name="form.reg_number").value = '345' 259 259 self.browser.getControl(name="password").value = 'secret' … … 429 429 student = Student() 430 430 student.reg_number = u'123456' 431 student. name = u'Klaus Tester'431 student.fullname = u'Klaus Tester' 432 432 test_student_id = self.app['students'].addStudent(student) 433 433 setpassword_path = 'http://localhost/app/setpassword' -
main/waeup.sirp/trunk/src/waeup/sirp/students/tests/test_catalog.py
r6733 r6818 44 44 # Create students 45 45 student = Student() 46 student. name = u'Bob Tester'46 student.fullname = u'Bob Tester' 47 47 student.student_id = u'A123456' 48 48 self.app['students'][student.student_id] = student … … 74 74 # We can find a certain name 75 75 cat = queryUtility(ICatalog, name='students_catalog') 76 results = cat.searchResults( name='Bob Tester')76 results = cat.searchResults(fullname='Bob Tester') 77 77 results = [x for x in results] # Turn results generator into list 78 78 assert len(results) == 1
Note: See TracChangeset for help on using the changeset viewer.