Changeset 16240 for main/waeup.aaue/trunk/src/waeup/aaue/students
- Timestamp:
- 17 Sep 2020, 07:34:46 (4 years ago)
- Location:
- main/waeup.aaue/trunk/src/waeup/aaue/students
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
main/waeup.aaue/trunk/src/waeup/aaue/students/browser.py
r16143 r16240 1076 1076 imported_ts = int(formvals[sid][2]) 1077 1077 except ValueError: 1078 error += '%s, ' % ticket.student.display_fullname 1079 ticket_error = True 1080 if score and ca and not ticket_error and score + ca > 100: 1078 1081 error += '%s, ' % ticket.student.display_fullname 1079 1082 ticket_error = True -
main/waeup.aaue/trunk/src/waeup/aaue/students/tests/test_browser.py
r15997 r16240 372 372 self.browser.open(self.edit_scores_url) 373 373 upload_ctrl = self.browser.getControl(name='uploadfile:file') 374 upload_file = StringIO(UPLOAD_CSV_TEMPLATE % ('65','52','77')) 375 upload_ctrl.add_file(upload_file, 'text/csv', 'myscores.csv') 376 self.browser.getControl("Update editable scores from").click() 377 self.assertTrue('TESTER, Anna have not be updated' in self.browser.contents) 378 # values have not been changed 379 self.assertEqual( 380 self.student['studycourse']['100']['COURSE1'].score, 55) 381 self.assertEqual( 382 self.student['studycourse']['100']['COURSE1'].ca, None) 383 self.assertEqual( 384 self.student['studycourse']['100']['COURSE1'].imported_ts, None) 385 self.browser.open(self.edit_scores_url) 386 upload_ctrl = self.browser.getControl(name='uploadfile:file') 374 387 upload_file = StringIO(UPLOAD_CSV_TEMPLATE % ('65','22','77')) 375 388 upload_ctrl.add_file(upload_file, 'text/csv', 'myscores.csv') 376 389 self.browser.getControl("Update editable scores from").click() 377 # value changed390 # values changed 378 391 self.assertEqual( 379 392 self.student['studycourse']['100']['COURSE1'].score, 65)
Note: See TracChangeset for help on using the changeset viewer.