Ignore:
Timestamp:
14 Dec 2012, 13:43:28 (12 years ago)
Author:
uli
Message:

Prove that get_students() supports mode filter.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • main/waeup.kofa/trunk/src/waeup/kofa/students/tests/test_export.py

    r9797 r9800  
    8585        return
    8686
     87    def test_get_students_by_current_mode(self):
     88        # we can filter out students in a certain mode.
     89        my_filter1 = StudentsQuery(current_mode='ug_ft')
     90        result = get_students(self.app, stud_filter=my_filter1)
     91        self.assertEqual(len(list(result)), 1)
     92
     93        my_filter2 = StudentsQuery(current_mode='NOTEXISTING')
     94        result = get_students(self.app, stud_filter=my_filter2)
     95        self.assertEqual(len(list(result)), 0)
     96        return
     97
    8798
    8899class StudentsExporterTest(StudentImportExportSetup):
Note: See TracChangeset for help on using the changeset viewer.