Index: /main/kofacustom.nigeria/trunk/src/kofacustom/nigeria/remita/applicantsbrowser.py
===================================================================
--- /main/kofacustom.nigeria/trunk/src/kofacustom/nigeria/remita/applicantsbrowser.py	(revision 14804)
+++ /main/kofacustom.nigeria/trunk/src/kofacustom/nigeria/remita/applicantsbrowser.py	(revision 14805)
@@ -214,5 +214,5 @@
     serviceTypeId = SERVICETYPEID
 
-    orderId = '3456346346'
+    #orderId = '3456346346'
     init_url = '/remita/ecomm/split/init.reg'
     amount='1000'
@@ -275,4 +275,5 @@
         if not module_activated(self.context.__parent__.__parent__.year):
             return
+        self.orderId = self.context.p_id
         error = self.init_update()
         if error:
Index: /main/kofacustom.nigeria/trunk/src/kofacustom/nigeria/remita/studentsbrowser.py
===================================================================
--- /main/kofacustom.nigeria/trunk/src/kofacustom/nigeria/remita/studentsbrowser.py	(revision 14804)
+++ /main/kofacustom.nigeria/trunk/src/kofacustom/nigeria/remita/studentsbrowser.py	(revision 14805)
@@ -222,5 +222,5 @@
     serviceTypeId = SERVICETYPEID
 
-    orderId = '3456346346'
+    #orderId = '3456346346'
     init_url = '/remita/ecomm/split/init.reg'
     amount='1000'
@@ -290,4 +290,5 @@
         if not module_activated(self.context.student.current_session):
             return
+        self.orderId = self.context.p_id
         error = self.init_update()
         if error:
Index: /main/kofacustom.nigeria/trunk/src/kofacustom/nigeria/remita/tests.py
===================================================================
--- /main/kofacustom.nigeria/trunk/src/kofacustom/nigeria/remita/tests.py	(revision 14804)
+++ /main/kofacustom.nigeria/trunk/src/kofacustom/nigeria/remita/tests.py	(revision 14805)
@@ -84,9 +84,15 @@
                 fullname='Anton Meier', email='am@xxx.de',
                 lineitems=self.lineitems)
-        self.rrr = resp['RRR'].rstrip()
+        return resp
 
     @external_test
     def test_get_JSON_POST_response(self):
-        self._get_transaction_data()
+        resp = self._get_transaction_data()
+        self.rrr = resp['RRR']
+        assert resp == {
+            u'status': u'Payment Reference generated',
+            u'orderID': self.orderId,
+            u'RRR': self.rrr,
+            u'statuscode': u'025'}
         resp = get_JSON_POST_response(
                 merchantId=self.merchantId, serviceTypeId=self.serviceTypeId,
@@ -97,9 +103,6 @@
                 lineitems=self.lineitems)
         assert resp == {
-            u'status': u'RRR Already Exist for the orderId',
-            u'orderID': self.orderId,
-            u'RRR': self.rrr + ' ',  # strange trailing whitespace which
-                                     # obviously does not belong to the RRR
-            u'statuscode': u'055'}
+            u'status': u'Duplicate Order Ref',
+            u'statuscode': u'028'}
 
         resp = get_payment_status_via_rrr(
@@ -113,7 +116,4 @@
         assert resp['status'] == '021'
         assert resp['amount'] == self.amount
-        assert resp['lineitems'] == [
-            {u'status': u'021', u'lineItemsId': u'itemid1'},
-            {u'status': u'021', u'lineItemsId': u'itemid2'}]
         assert resp['RRR'] == self.rrr
         assert resp['message'] == u'Transaction Pending'
@@ -200,10 +200,10 @@
         self.browser.getLink("Pay via Remita").click()
         # The RRR has been retrieved
-        self.assertTrue('<input name="rrr" type="hidden" value="%s">' % self.rrr
+        self.assertTrue('<input name="rrr" type="hidden" value="%s">'
+            % self.payment.r_pay_reference
             in self.browser.contents)
         self.assertTrue(
             'action="http://www.remitademo.net/remita/ecomm/finalize.reg"'
             in self.browser.contents)
-        self.assertEqual(self.payment.r_pay_reference, self.rrr)
         self.assertEqual(self.payment.r_company, 'remita')
         # Retrieval has been logged
@@ -214,5 +214,5 @@
             'zope.mgr - kofacustom.nigeria.remita.studentsbrowser.RemitaPageStudent'
             ' - K1000000 - RRR retrieved: %s, ServiceTypeId: %s'
-            % (self.rrr, self.serviceTypeId) in logcontent)
+            % (self.payment.r_pay_reference, self.serviceTypeId) in logcontent)
 
         # Means of testing end here.
@@ -385,7 +385,7 @@
         self.browser.getLink("Pay via Remita").click()
         # The RRR has been retrieved
-        self.assertTrue('<input name="rrr" type="hidden" value="%s">' % self.rrr
-            in self.browser.contents)
-        self.assertEqual(self.payment.r_pay_reference, self.rrr)
+        self.assertTrue('<input name="rrr" type="hidden" value="%s">'
+            % self.payment.r_pay_reference
+            in self.browser.contents)
         self.assertEqual(self.payment.r_company, 'remita')
         # Retrieval has been logged
@@ -396,5 +396,7 @@
             'zope.mgr - kofacustom.nigeria.remita.applicantsbrowser.RemitaPageApplicant'
             ' - %s - RRR retrieved: %s, ServiceTypeId: %s'
-            % (self.applicant.applicant_id, self.rrr, self.serviceTypeId)
+            % (self.applicant.applicant_id,
+               self.payment.r_pay_reference,
+               self.serviceTypeId)
             in logcontent)
         # Means of testing end here.
