Functional Testing
Testing scenarios
From PBMS
Independent of PBMS
Rest API
Create envelope - Happy path
Create envelope - with non-existent Program Mnemonic
Create envelope - with schedule date in the past
Create Disbursements - Happy path
Create Disbursements - with invalid envelope ID
Create Disbursements - with cancelled envelope
Create Disbursements - with no beneficiary ID
Create Disbursements - with duplicate beneficiary ID
Create Disbursements - with negative disbursal amount
Create Disbursements - where the total of all disbursements cross the sum specified in the envelope
Create Disbursements - where number of disbursements cross the number specified in the envelope
Cancel Envelope - Happy path
Cancel Envelope - Invalid envelope ID
Cancel Envelope - already cancelled envelope
Cancel Disbursements - Happy path
Cancel Disbursements - Invalid disbursement ID in a batch - 1 is invalid whereas other disbursement IDs are valid
Downstream Batch Testing - Single Scenario covering multiple use cases
Create 1 envelope with 1002 disbursements, totalling upto USD 502,503 - disbursement amounts as 1, 2, 3....upto 1002 - schedule date should be in the future. The disbursement with USD 1002 - should have an invalid Beneficiary ID - Beneficiary ID should not be present in mapper
Cancel 1 disbursement in this envelope, the disbursement with USD 1001
Now check disbursement_envelope_status - it should show 1001 disbursements with amount as 500,500 + 1002 = 501,502
Manually update the envelope schedule date to TODAY - so that the downstream batch picks up the envelope for shipment
Give it 5 minutes - Now check disbursement_envelope_status - it should show 1000 disbursements as shipped (1 is cancelled, 1 is invalid beneficiary ID)
Wait for 10 minutes
Iteratively check all 1002 - disbursement_status. Disbursement IDs - 1 to 1000 should show reconciled. Some of them should show reversed (about 30%) -- ID 1001 should show cancelled and ID 1002 - should show ??
Negative conditions for MT940
In Example Bank for the above Envelope add Wrong entries in accounting log
Add duplicate Debit for Disbursement ID - 1 - DUPLICATE_DEBIT
Add a Debit for Disbursement ID - 1003 - INVALID_DISBURSEMENT_ID
Add a Reversal Debit for Disbursement ID - 1002 (which had invalid beneficiary ID)
Generate Account Statement and upload into Bridge. Check for Reconciliation Errors. There should be these 3 entries that should show up in Recon Errors.
Integration Testing with G2P MIS
Vanilla happy path - Program has 100 beneficiaries, we enrol all 100 beneficiaries into a new cycle and disburse the payments. All 100 beneficiaries should have their IDs mapped in SPAR. Batch size = 100, so that all disbursements happen in a single batch
Repeat scenario 1 with a reduced batch size of 10. You should see 10 batches between G2P MIS and G2P Bridge
Repeat scenario 1 with 2 beneficiary IDs removed from SPAR. Check failure handling for the 2 missing beneficiaries
Create a new cycle and enrol only 50 beneficiaries into the cycle. Disburse and reconcile the envelope numbers and the disbursement numbers.
Check Envelope Summary for all scenarios and check PDF rendering from the pop up page.
Last updated