Index: /main/kofacustom.nigeria/trunk/src/kofacustom/nigeria/students/tests/test_export.py
===================================================================
--- /main/kofacustom.nigeria/trunk/src/kofacustom/nigeria/students/tests/test_export.py	(revision 12107)
+++ /main/kofacustom.nigeria/trunk/src/kofacustom/nigeria/students/tests/test_export.py	(revision 12108)
@@ -2,4 +2,5 @@
 from zope.component import queryUtility
 from zope.interface.verify import verifyObject, verifyClass
+from hurry.workflow.interfaces import IWorkflowState
 from waeup.kofa.interfaces import ICSVExporter
 from waeup.kofa.schoolgrades import ResultEntry
@@ -8,5 +9,6 @@
 from kofacustom.nigeria.utils.utils import NigeriaKofaUtils
 from kofacustom.nigeria.students.export import (
-    NigeriaStudentExporter, NigeriaStudentPaymentsExporter)
+    NigeriaStudentExporter, NigeriaStudentPaymentsExporter,
+    ClearanceRequestedStudentExporter)
 from kofacustom.nigeria.testing import FunctionalLayer
 
@@ -111,2 +113,37 @@
             )
         return
+
+class ClearanceRequestedStudentExporterTest(StudentImportExportSetup):
+
+    layer = FunctionalLayer
+
+    def setUp(self):
+        super(ClearanceRequestedStudentExporterTest, self).setUp()
+        self.setup_for_export()
+        return
+
+    def test_ifaces(self):
+        # make sure we fullfill interface contracts
+        obj = ClearanceRequestedStudentExporter()
+        verifyObject(ICSVExporter, obj)
+        verifyClass(ICSVExporter, ClearanceRequestedStudentExporter)
+        return
+
+    def test_export_all(self):
+        # we can really export students
+        # set values we can expect in export file
+        self.setup_student(self.student)
+        self.student.date_of_invitation = 'Come soon'
+        IWorkflowState(self.student).setState('clearance requested')
+        exporter = ClearanceRequestedStudentExporter()
+        exporter.export_all(self.app, self.outfile)
+        result = open(self.outfile, 'rb').read()
+        self.assertMatches(
+            'student_id,reg_number,display_fullname,state,current_session,'
+            'history,date_of_invitation\r\n'
+            'A111111,123,Anna M. Tester,clearance requested,'
+            '2012,2014-12-02 07:17:02 WAT - Record created by system,'
+            'Come soon\r\n',
+            result
+            )
+        return
