Ignore:
Timestamp:
28 Aug 2020, 08:36:00 (4 years ago)
Author:
Henrik Bettermann
Message:

Modify and adjust saveCourses.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • main/kofacustom.iuokada/trunk/src/kofacustom/iuokada/applicants/tests/test_browser.py

    r16075 r16220  
    9090        self.browser.getControl(name="form.middlename").value = 'Anthony'
    9191        self.browser.getControl(name="form.lastname").value = 'Tester'
    92         self.browser.getControl(name="custom.course1").value = ['CERT1']
    9392        self.browser.getControl(name="form.date_of_birth").value = '09/09/1988'
    9493        self.browser.getControl(name="form.sex").value = ['m']
     
    101100        self.assertEqual(self.browser.headers['Status'], '200 Ok')
    102101        self.fill_correct_values()
     102        self.browser.getControl(name="custom.course1").value = ['']
     103        self.browser.getControl("Save").click()
     104        self.assertTrue('Please select your 1st Choice Course of Study.'
     105            in self.browser.contents)
     106        self.browser.getControl(name="custom.course1").value = ['CERT1']
    103107        self.browser.getControl("Save").click()
    104108        self.assertEqual(self.applicant.course1, self.certificate)
     
    113117        open(path, 'wb').write(self.browser.contents)
    114118        print "Sample application_slip.pdf written to %s" % path
    115         # Log entries have been added
     119        # Log entries have been added (course1 is missing because it was already stored)
    116120        logfile = os.path.join(
    117121            self.app['datacenter'].storage, 'logs', 'applicants.log')
     
    120124            'zope.mgr - kofacustom.iuokada.applicants.browser.CustomApplicantManageFormPage - '
    121125            '%s - saved: firstname + middlename + lastname + date_of_birth '
    122             '+ sex + email + course1'
     126            '+ sex + email'
    123127            % (self.applicant.applicant_id)
    124128            in logcontent)
Note: See TracChangeset for help on using the changeset viewer.