Ignore:
Timestamp:
20 Sep 2018, 07:04:17 (6 years ago)
Author:
Henrik Bettermann
Message:

Reorganise interfaces.

Transcript processing views and viewlets are now in the context of studycourses. Officers can now validate, sign and release transcripts directly on the transcript page.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • main/waeup.kofa/branches/henrik-transcript-workflow/src/waeup/kofa/students/tests/test_browser.py

    r15154 r15155  
    21232123        IWorkflowState(self.student).setState('transcript requested')
    21242124        notify(grok.ObjectModifiedEvent(self.student))
    2125         self.student.transcript_comment = (
     2125        self.student['studycourse'].transcript_comment = (
    21262126            u'On 07/08/2013 08:59:54 UTC K1000000 wrote:\n\nComment line 1 \n'
    21272127            'Comment line2\n\nDispatch Address:\nAddress line 1 \n'
     
    21752175        self.assertTrue('Form has been saved' in self.browser.contents)
    21762176        # Officer can validate the transcript
    2177         self.browser.open(self.student_path)
     2177        self.browser.open(self.studycourse_path + '/transcript')
    21782178        self.browser.getLink("Validate transcript").click()
    21792179        # After validation all manage forms are locked.
     
    22072207        self.assertTrue(
    22082208            u'Electronically signed by Ruth Gordon (mrtranscript) on '
    2209             in self.student.transcript_signees)
     2209            in self.student['studycourse'].transcript_signees)
    22102210        # Officer can release the transcript
    2211         self.browser.open(self.student_path)
     2211        self.browser.open(self.studycourse_path + '/transcript')
    22122212        self.browser.getLink("Release transcript").click()
    22132213        self.assertTrue(' UTC K1000000 wrote:<br><br>Comment line 1 <br>'
     
    22202220            'UTC mrtranscript wrote:\n\nHello,\nYour transcript has '
    22212221            'been sent to the address provided.\n\n'
    2222             in self.student.transcript_comment)
     2222            in self.student['studycourse'].transcript_comment)
    22232223        # The comment has been logged
    22242224        logfile = os.path.join(
     
    22502250                         'application/pdf')
    22512251        # Transcript views are no longer accesssible
    2252         self.browser.open(self.student_path)
    2253         self.assertFalse('studycourse/transcript' in self.browser.contents)
    22542252        self.browser.open(self.studycourse_path)
    22552253        self.assertFalse('studycourse/transcript' in self.browser.contents)
     
    22642262        self.assertFalse('Final Transcript' in self.browser.contents)
    22652263        # ... and transcript process information has been removed
    2266         self.assertEqual(self.student.transcript_comment, None)
    2267         self.assertEqual(self.student.transcript_signees, None)
     2264        self.assertEqual(self.student['studycourse'].transcript_comment, None)
     2265        self.assertEqual(self.student['studycourse'].transcript_signees, None)
    22682266
    22692267    def test_landingpage_transcript_officer(self):
     
    34303428            '... UTC K1000000 wrote:\n\nComment line 1 \n'
    34313429            'Comment line2\n\nDispatch Address:\nAddress line 1 \n'
    3432             'Address line2\n\n', self.student.transcript_comment)
     3430            'Address line2\n\n', self.student['studycourse'].transcript_comment)
    34333431        # The comment has been logged
    34343432        logfile = os.path.join(
     
    36993697            'firstname,flash_notice,lastname,matric_number,middlename,nationality,'
    37003698            'officer_comment,perm_address,personal_updated,phone,reg_number,'
    3701             'sex,student_id,suspended,suspended_comment,transcript_comment,'
    3702             'transcript_signees,password,state,history,certcode,is_postgrad,'
     3699            'sex,student_id,suspended,suspended_comment,'
     3700            'password,state,history,certcode,is_postgrad,'
    37033701            'current_level,current_session\r\n'
    37043702            ',,1981-02-04#,aa@aa.ng,,Anna,,Tester,234,,,,,,'
    3705             '1234#,123,m,K1000000,0,,,,{SSHA}' in self.browser.contents)
     3703            '1234#,123,m,K1000000,0,,{SSHA}' in self.browser.contents)
    37063704
    37073705    def test_payment_dates(self):
     
    38053803            'firstname,flash_notice,lastname,matric_number,middlename,nationality,'
    38063804            'officer_comment,perm_address,personal_updated,phone,reg_number,'
    3807             'sex,student_id,suspended,suspended_comment,transcript_comment,'
    3808             'transcript_signees,password,state,history,certcode,is_postgrad,'
     3805            'sex,student_id,suspended,suspended_comment,'
     3806            'password,state,history,certcode,is_postgrad,'
    38093807            'current_level,current_session\r\n'
    38103808            ',,1981-02-04#,aa@aa.ng,,Anna,,Tester,234,,,,,,'
    3811             '1234#,123,m,K1000000,0,,,,{SSHA}' in self.browser.contents)
     3809            '1234#,123,m,K1000000,0,,{SSHA}' in self.browser.contents)
    38123810        self.assertEqual(len(self.app['datacenter'].running_exports), 1)
    38133811        job_id = self.app['datacenter'].running_exports[0][0]
Note: See TracChangeset for help on using the changeset viewer.