Changeset 15696
- Timestamp:
- 20 Oct 2019, 20:06:20 (5 years ago)
- Location:
- main/kofacustom.iuokada/trunk/src/kofacustom/iuokada
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
main/kofacustom.iuokada/trunk/src/kofacustom/iuokada/interswitch/browser.py
r15684 r15696 75 75 xmldict['provider_item_name'] = PROVIDER_ITEM_NAME 76 76 # Institution data 77 xmldict['institution_acct'] = '00000000' 78 xmldict['institution_bank_id'] = '00' 79 xmldict['institution_amt'] = '0.0' 77 xmldict['institution_acct'] = '0040484781' 78 xmldict['institution_bank_id'] = '31' 80 79 provider_amt = 0.0 81 80 self.pay_item_id = '103' # must be provided by Interswitch … … 136 135 xmldict = {} 137 136 provider_amt = 400.0 138 xmldict['institution_acct'] = '00 000000000'139 xmldict['institution_bank_id'] = ' 00'137 xmldict['institution_acct'] = '0040484781' 138 xmldict['institution_bank_id'] = '31' 140 139 xmldict['detail_ref'] = self.context.p_id 141 140 xmldict['provider_amt'] = 100 * provider_amt -
main/kofacustom.iuokada/trunk/src/kofacustom/iuokada/interswitch/tests.py
r15663 r15696 79 79 self.browser.contents) 80 80 self.assertTrue( 81 'item_name="Tuition Plus (total amount)" item_amt="39 85000" bank_id="00" acct_num="00000000"' in81 'item_name="Tuition Plus (total amount)" item_amt="3970000" bank_id="31" acct_num="0040484781"' in 82 82 self.browser.contents) 83 83 -
main/kofacustom.iuokada/trunk/src/kofacustom/iuokada/students/browser.py
r15563 r15696 39 39 NigeriaExportPDFPaymentSlip, 40 40 NigeriaExportPDFClearanceSlip, 41 NigeriaExportPDFCourseRegistrationSlip, 41 42 ) 42 43 … … 46 47 from kofacustom.iuokada.interfaces import MessageFactory as _ 47 48 49 class CustomExportPDFCourseRegistrationSlip( 50 NigeriaExportPDFCourseRegistrationSlip): 51 """Deliver a PDF slip of the context. 52 """ 53 54 def _signatures(self): 55 return ( 56 ['Student Signature'], 57 ['HoD / Course Adviser Signature'], 58 ['College Officer Signature'], 59 ['Dean Signature'] 60 ) 61 62 #def _sigsInFooter(self): 63 # return (_('Student'), 64 # _('HoD / Course Adviser'), 65 # _('College Officer'), 66 # _('Dean'), 67 # ) 68 # return () -
main/kofacustom.iuokada/trunk/src/kofacustom/iuokada/students/tests/test_browser.py
r15563 r15696 31 31 from waeup.kofa.students.accommodation import BedTicket 32 32 from waeup.kofa.testing import FunctionalTestCase 33 from waeup.kofa.browser.tests.test_pdf import samples_dir 33 34 from waeup.kofa.interfaces import ( 34 35 IExtFileStore, IFileStoreNameChooser) … … 44 45 def test_dummytest(self): 45 46 return 47 48 49 class StudentUITests(StudentsFullSetup): 50 # Tests for Student class views and pages 51 52 layer = FunctionalLayer 53 54 def test_student_course_registration(self): 55 IWorkflowState(self.student).setState('school fee paid') 56 self.browser.open(self.login_path) 57 self.browser.getControl(name="form.login").value = self.student_id 58 self.browser.getControl(name="form.password").value = 'spwd' 59 self.browser.getControl("Login").click() 60 # Now students can add the current study level 61 self.browser.getLink("Study Course").click() 62 self.browser.getLink("Add course list").click() 63 self.assertMatches('...Add current level 100 (Year 1)...', 64 self.browser.contents) 65 self.browser.getControl("Create course list now").click() 66 # Students can open the pdf course registration slip 67 self.browser.open( 68 self.student_path + '/studycourse/100/course_registration_slip.pdf') 69 self.assertEqual(self.browser.headers['Status'], '200 Ok') 70 self.assertEqual(self.browser.headers['Content-Type'], 'application/pdf') 71 path = os.path.join(samples_dir(), 'course_registration_slip.pdf') 72 open(path, 'wb').write(self.browser.contents) 73 print "Sample PDF course_registration_slip.pdf written to %s" % path
Note: See TracChangeset for help on using the changeset viewer.