Ignore:
Timestamp:
27 May 2015, 15:26:26 (10 years ago)
Author:
Henrik Bettermann
Message:

Add Payment class attribute created_online to mark payment tickets
which are added online and not by import. This attribute is needed in
custom packages when sending data to payment gateways.

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

    r13003 r13005  
    904904                           self.browser.contents)
    905905        self.assertEqual(self.student['payments'][value].amount_auth, 40000.0)
     906        self.assertEqual(self.student['payments'][value].created_online, True)
    906907        payment_url = self.browser.url
    907908        logfile = os.path.join(
  • main/waeup.kofa/trunk/src/waeup/kofa/students/tests/test_export.py

    r12971 r13005  
    744744        self.assertEqual(
    745745            result,
    746             'ac,amount_auth,creation_date,p_category,p_current,p_id,'
     746            'ac,amount_auth,created_online,creation_date,p_category,p_current,p_id,'
    747747            'p_item,p_level,p_session,p_state,payment_date,r_amount_approved,'
    748748            'r_code,r_desc,student_id,state,current_session\r\n'
    749749
    750             ',0.0,2012-04-01 13:12:01#,,1,,,,,unpaid,,0.0,,,,,\r\n'
     750            ',0.0,0,2012-04-01 13:12:01#,,1,,,,,unpaid,,0.0,,,,,\r\n'
    751751            )
    752752        return
     
    762762        self.assertEqual(
    763763            result,
    764             'ac,amount_auth,creation_date,p_category,p_current,p_id,'
     764            'ac,amount_auth,created_online,creation_date,p_category,p_current,p_id,'
    765765            'p_item,p_level,p_session,p_state,payment_date,r_amount_approved,'
    766766            'r_code,r_desc,student_id,state,current_session\r\n'
    767767
    768             '666,12.12,2012-04-01 13:12:01#,schoolfee,1,my-id,'
     768            '666,12.12,0,2012-04-01 13:12:01#,schoolfee,1,my-id,'
    769769            'p-item,100,2012,paid,2012-04-01 14:12:01#,12.12,'
    770770            'r-code,,A111111,created,2012\r\n'
     
    781781        self.assertEqual(
    782782            result,
    783             'ac,amount_auth,creation_date,p_category,p_current,p_id,'
     783            'ac,amount_auth,created_online,creation_date,p_category,p_current,p_id,'
    784784            'p_item,p_level,p_session,p_state,payment_date,r_amount_approved,'
    785785            'r_code,r_desc,student_id,state,current_session\r\n'
    786786
    787             '666,12.12,2012-04-01 13:12:01#,schoolfee,1,my-id,'
     787            '666,12.12,0,2012-04-01 13:12:01#,schoolfee,1,my-id,'
    788788            'p-item,100,2012,paid,2012-04-01 14:12:01#,12.12,'
    789789            'r-code,,A111111,created,2012\r\n'
     
    800800        self.assertEqual(
    801801            result,
    802             'ac,amount_auth,creation_date,p_category,p_current,p_id,'
     802            'ac,amount_auth,created_online,creation_date,p_category,p_current,p_id,'
    803803            'p_item,p_level,p_session,p_state,payment_date,r_amount_approved,'
    804804            'r_code,r_desc,student_id,state,current_session\r\n'
    805805
    806             '666,12.12,2012-04-01 13:12:01#,schoolfee,1,my-id,'
     806            '666,12.12,0,2012-04-01 13:12:01#,schoolfee,1,my-id,'
    807807            'p-item,100,2012,paid,2012-04-01 14:12:01#,12.12,'
    808808            'r-code,,A111111,created,2012\r\n'
     
    822822        self.assertEqual(
    823823            result,
    824             'ac,amount_auth,creation_date,p_category,p_current,p_id,'
     824            'ac,amount_auth,created_online,creation_date,p_category,p_current,p_id,'
    825825            'p_item,p_level,p_session,p_state,payment_date,r_amount_approved,'
    826826            'r_code,r_desc,student_id,state,current_session\r\n'
    827827
    828             '666,12.12,2012-04-01 13:12:01#,schoolfee,1,my-id,'
     828            '666,12.12,0,2012-04-01 13:12:01#,schoolfee,1,my-id,'
    829829            'p-item,100,2012,paid,2012-04-01 14:12:01#,12.12,'
    830830            'r-code,,A111111,created,2012\r\n'
     
    857857        self.assertEqual(
    858858            result,
    859             'ac,amount_auth,creation_date,p_category,p_current,p_id,'
     859            'ac,amount_auth,created_online,creation_date,p_category,p_current,p_id,'
    860860            'p_item,p_level,p_session,p_state,payment_date,r_amount_approved,'
    861861            'r_code,r_desc,student_id,state,current_session\r\n'
    862862
    863             '666,12.12,2012-04-01 13:12:01#,schoolfee,1,my-id,'
     863            '666,12.12,0,2012-04-01 13:12:01#,schoolfee,1,my-id,'
    864864            'p-item,100,2012,paid,2012-04-01 14:12:01#,12.12,'
    865865            'r-code,,A111111,created,2012\r\n'
     
    873873        self.assertEqual(
    874874            result,
    875             'ac,amount_auth,creation_date,p_category,p_current,p_id,'
     875            'ac,amount_auth,created_online,creation_date,p_category,p_current,p_id,'
    876876            'p_item,p_level,p_session,p_state,payment_date,r_amount_approved,'
    877877            'r_code,r_desc,student_id,state,current_session\r\n'
     
    884884        self.assertEqual(
    885885            result,
    886             'ac,amount_auth,creation_date,p_category,p_current,p_id,'
     886            'ac,amount_auth,created_online,creation_date,p_category,p_current,p_id,'
    887887            'p_item,p_level,p_session,p_state,payment_date,r_amount_approved,'
    888888            'r_code,r_desc,student_id,state,current_session\r\n'
     
    917917        self.assertEqual(
    918918            result,
    919             'ac,amount_auth,creation_date,p_category,p_current,p_id,'
     919            'ac,amount_auth,created_online,creation_date,p_category,p_current,p_id,'
    920920            'p_item,p_level,p_session,p_state,payment_date,r_amount_approved,'
    921921            'r_code,r_desc,student_id,state,current_session\r\n'
     
    927927        self.assertEqual(
    928928            result,
    929             'ac,amount_auth,creation_date,p_category,p_current,p_id,'
     929            'ac,amount_auth,created_online,creation_date,p_category,p_current,p_id,'
    930930            'p_item,p_level,p_session,p_state,payment_date,r_amount_approved,'
    931931            'r_code,r_desc,student_id,state,current_session\r\n'
    932932
    933             '666,12.12,2012-04-01 13:12:01#,schoolfee,1,my-id,'
     933            '666,12.12,0,2012-04-01 13:12:01#,schoolfee,1,my-id,'
    934934            'p-item,100,2012,unpaid,2012-04-01 14:12:01#,12.12,'
    935935            'r-code,,A111111,created,2012\r\n'
     
    955955        self.assertEqual(
    956956            result,
    957             'ac,amount_auth,creation_date,p_category,p_current,p_id,p_item,'
     957            'ac,amount_auth,created_online,creation_date,p_category,p_current,p_id,p_item,'
    958958            'p_level,p_session,p_state,payment_date,r_amount_approved,r_code,'
    959959            'r_desc,student_id,matric_number,reg_number,firstname,middlename,lastname,'
    960960            'state,current_session,entry_session,entry_mode,faccode,depcode,certcode\r\n'
    961961
    962             '666,12.12,2012-04-01 13:12:01#,schoolfee,1,my-id,p-item,100,2012,'
     962            '666,12.12,0,2012-04-01 13:12:01#,schoolfee,1,my-id,p-item,100,2012,'
    963963            'paid,2012-04-01 14:12:01#,12.12,r-code,,A111111,234,123,'
    964964            'Anna,M.,Tester,created,2012,2010,ug_ft,NA,NA,CERT1\r\n'
Note: See TracChangeset for help on using the changeset viewer.