Changeset 13925


Ignore:
Timestamp:
13 Jun 2016, 01:12:36 (9 years ago)
Author:
uli
Message:

Move template out of class.

It is a constant in fact.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • main/waeup.kofa/branches/uli-scores-upload/src/waeup/kofa/students/tests/test_browser.py

    r13924 r13925  
    38543854
    38553855
     3856UPLOAD_CSV_TEMPLATE = (
     3857    'matric_number,student_id,display_fullname,level,code,level_session,'
     3858    'score\r\n'
     3859    '234,K1000000,Anna Tester,100,COURSE1,2004,%s\r\n')
     3860
    38563861class LecturerUITests(StudentsFullSetup):
    38573862    # Tests for UI actions when acting as lecturer.
     
    40564061            'K1000000,Anna Tester,100,COURSE1,2004,\r\n')
    40574062
    4058     UPLOAD_CSV_TEMPLATE = (
    4059         'matric_number,student_id,display_fullname,level,code,'
    4060         'level_session,score\r\n'
    4061         '234,K1000000,Anna Tester,100,COURSE1,2004,%s\r\n')
    4062 
    40634063    def test_scores_csv_upload_available(self):
    40644064        # lecturers can upload a CSV file to set values.
     
    40684068        self.browser.open(self.edit_scores_url)
    40694069        upload_ctrl = self.browser.getControl(name='uploadfile:file')
    4070         upload_file = StringIO(self.UPLOAD_CSV_TEMPLATE % '65')
     4070        upload_file = StringIO(UPLOAD_CSV_TEMPLATE % '65')
    40714071        upload_ctrl.add_file(upload_file, 'text/csv', 'myscores.csv')
    40724072        self.browser.getControl("Update scores").click()
Note: See TracChangeset for help on using the changeset viewer.