Changeset 13296 for main/waeup.uniben/trunk/src/waeup
- Timestamp:
- 7 Oct 2015, 20:25:08 (9 years ago)
- Location:
- main/waeup.uniben/trunk/src/waeup/uniben/students
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
main/waeup.uniben/trunk/src/waeup/uniben/students/tests/test_browser.py
r13283 r13296 618 618 error, payment = utils.setPaymentDetails('bed_allocation', 619 619 self.student, None, None) 620 self.assertTrue(u'Amount could not be determined.' in error) 621 self.student['studycourse'].current_session = 2004 622 self.student['studycourse'].entry_session = 2004 623 self.student['studycourse'].current_level = 100 624 error, payment = utils.setPaymentDetails('bed_allocation', 625 self.student, None, None) 620 626 self.assertEqual(payment.p_level, 100) 621 627 self.assertEqual(payment.p_session, 2004) 622 self.assertEqual(payment.amount_auth, 150.0)623 self.assertEqual(payment.p_item, u'regular_male_ re')628 self.assertEqual(payment.amount_auth, 650.0) # plus 500 student union 629 self.assertEqual(payment.p_item, u'regular_male_fr') 624 630 self.assertEqual(error, None) 625 631 … … 985 991 self.browser.getControl(name="ac_number").value = sfenumber 986 992 self.browser.getControl("Create bed ticket").click() 987 self.assertMatches('...Hall 1, Block A, Room 101, Bed C...',993 self.assertMatches('...Hall 1, Block/Unit A, Room 101, Bed C...', 988 994 self.browser.contents) 989 995 # Bed has been allocated. … … 995 1001 # The bed ticket displays the data correctly. 996 1002 self.browser.open(self.acco_path + '/2004') 997 self.assertMatches('...Hall 1, Block A, Room 101, Bed C...',1003 self.assertMatches('...Hall 1, Block/Unit A, Room 101, Bed C...', 998 1004 self.browser.contents) 999 1005 self.assertMatches('...2004/2005...', self.browser.contents) -
main/waeup.uniben/trunk/src/waeup/uniben/students/utils.py
r13295 r13296 116 116 sex = 'male' 117 117 special_handling = 'regular' 118 if student.faccode == 'MED': 119 special_handling = 'clinical' 118 120 d['bt'] = u'%s_%s_%s' % (special_handling,sex,bt) 119 121 return d … … 181 183 if stage == 'fr': 182 184 amount += 500.0 183 el se:185 elif stage == 'fi' and student.current_verdict in ('A', 'B'): 184 186 amount += 300.0 187 else: 188 amount = 0.0 185 189 elif category == 'hostel_maintenance': 186 190 amount = 0.0
Note: See TracChangeset for help on using the changeset viewer.