Data Warehouse 1.0 Non-automated ETL Testing Summary
mifos_dw_etl_test_dataset.zip
The Requirements/Test Summary
This is (probably) a temporary wiki page showing details of manual testing of Data Warehouse 1.0.  Attached is the mifos 1.6.1 database backup (mifos_dw_etl_test_dataset.zip) which has the test data used during ETL testing.  This page gives some idea of what's involved in the ETL job that moves data from mifos to the data warehouse.  The actual Pentaho Data Integration job (CreateDataWarehouse.kjb) is in the business intelligence git repository (git://mifos.git.sourceforge.net / mifos/bi).  Manual testing was by query inspection and running against some standard reports (Loan Officer Detailed Report, MFI Progress Report, Due vs Collect Branch Report and Due vs Collected Loan Officer Report).
Note: Â The tests on this page have been automated.
The Data Warehouse ETL job should...
- copy over the simple 'dimensions' such as products, currencies, offices, personnels correctly
- handle being run against an initialised mifos database
- handle simple hierarchy (loan officer, center, group, client, loan/savings account) creation.
Involves handling new entries and catering for status changes when making groups, clients and accounts active. Â - handle when a client without a group membership is created and has its status changed and has a loan and a savings account.Â
- handle when a group without center hierarchy is created and has its status changed and has a client with a loan and a savings account and has its own savings and loan account as well.Â
- handle when a center has a savings account.
- Â
- handle moving a client from one group to another in the same center.Â
- handle moving a client from one group to another in the same branchÂ
- handle moving a client from one group to another in a different branch
- handle removing group membership from a client.Â
- handle moving client with no group membership to another branch.Â
- handle a client with no group membership becoming a group member.Â
- handle a Loan Officer change for a client with no group membership.Â
- handle a Loan Officer change for a group with no hierarchy.
- handle moving group with no hierarchy from one branch to another.
- handle center change for a group to center in same branch
- handle center change for a group to center in different branch
- handle adding a group hierarchy back to a center
- should handle a Loan Officer change for a center
- Â
- All savings transactions should link to the latest savings account entry that is 'open' (active or inactive but not closed) for the date matching the transaction action_date.Â
- All repayment transactions should link to the latest loan account entry that is 'active' (good or bad standing)for the date matching the transaction action_dateÂ
- All write off transactions should link to the loan account entry having a loan writeoff status. Â
Write-off account_action_id is 15 - 'AccountAction-LoanWrittenOff'Â - All disbursal transactions should link to the latest loan account entry that is pre-active -Â Â 'AccountState-ApplicationApproved'standing or 'AccountState-DisbursedToLo
(which is probably not used and deprecated) for the date matching the transaction action_date - All Customer Miscellaneous charges and penalties (that are setup on customer_schedule) should appear on the customer charges and fees table linked to an active or on-hold customer
- All Customer Fees (that are setup on customer_fee_schedule) should appear on the customer charges and fees table linked to an active or on-hold custome
Issues Outstanding
MIFOS-3871                    - Data Warehouse doesnt handle removing group membership from a client. (fixed)
MIFOS-3872               - Data Warehouse - mifos doesnt currently audit group transfer (no center hierarchy) to another branch.(fixed in 1.7)
MIFOS-3873              - Data Warehouse - mifos doesnt currently audit status change for group transfer (within a center hierarchy) to another branch (fixed in 1.7)
MIFOS-3479        - account_state_change_history and account tables not correctly updated when loan adjustments are made (history fixed for 1.7 release, closed date fix outstanding)
Basic Copy Data and Status Tests
Requirement |
Test |
Result |
---|---|---|
Copy over the simple 'dimensions' such as products, currencies, offices, personnels correctly |
Setup up an office hierarchy, some loan and savings products, some system users (loan officer and non loan officers) and run ETL |
Pass. Â |
Handle being run against an initialised mifos database |
run ETL against an initialised mifos 1.6.1 database |
Pass |
Handle simple hierarchy (loan officer, center, group, client, loan/savings account) creation. Â |
Setup a center hierarchy down to clients having loan and savings accounts |
Pass. Â All new customers and accounts are added to the datawarehouse as expected |
Handle when a client without a group membership is created and has its status changed and has a loan and a savings account. |
Client: Â BO 1 / client w/o group mem xxx 0003-000000028 |
Pass. New client and accounts are added to the datawarehouse as expected |
Handle when a group without center hierarchy is created and has its status changed and has a client with a loan and a savings account and has its own savings and loan account as well. |
Group: group w/o center hierarchy 0004-000000029Â |
Pass. New group, client and all accounts are added to the datawarehouse as expected |
Handle when a center has a savings account. |
Center: center with savings a/c 0004-000000031 |
Pass. Center and savings account added as expected. |
Customer Hierarchy Change Tests
Note: There are 3 types of change. Â New, Hierarchy and Status and if they occur on the same day they are processed in the order New, Hierarchy then Status. Â This means it can be technically wrong. Â For example, Â if you create a client, make her active then move the client to another group all on the same day it will show as new client, move to new group, make active. Â Couldn't distinguish which event was first because auditing in mifos is at a day level.
Moving clients/groups can only be done if no active accounts exists for that client (all accounts must be closed). Â Except for clients with no group membership... moving to another branch puts them on-hold and the loan officer is removed and has to be reassigned.
Requirement |
Test |
Result |
---|---|---|
Handle moving a client from one group to another in the same center. |
Group: group dw1 1 - 0003-000000002 |
Pass. Client entry added to reflect new group. and  savings entry added to link to new client entry. |
Handle moving a client from one group to another in the same branch |
Group: group dw1 1 - 0003-000000002 |
Pass. Client entry added to reflect new group. and  loan entry added to link to new client entry. |
Handle moving a client from one group to another in a different branch |
Group: group dw1 1 - 0003-000000002 |
Pass.  Client entry added to reflect new group. and  savings entry added to link to new client entry. |
Handle removing group membership from a client. |
client: client remove group membership xxx  0003-000000050 |
Fail. Â The data is ETL's but the outcome looks as if the client had not group membership from the start. Â |
Handle moving client with no group membership to another branch. |
Client: client w/o gr memb xfer to branch xxx 0003-000000045 |
Pass. Â Client and savings account show application of 'Loan Officer Assigned', 'Branch membership' |
Handle a client with no group membership becoming a group member. |
Client: client add back to group hierarchy after xxx 0003-000000051 |
Pass. |
Handle a Loan Officer change for a client with no group membership. |
Client: client w/o grp memb hier LO change xxx 0003-000000044 |
Pass. Client and Savings entries as expected. Â As LO change was done on same day as client and |
Handle a Loan Officer change for a group with no hierarchy. |
Group: group w/o center hier LO change 0003-000000042Â |
Pass. Group, client and account entries as expected. Â As LO change was done on same day as |
Handle moving group with no hierarchy from one branch to another. |
Group: group w/o center hier xfer branch 0003-000000046Â |
Fail. Â Mifos audit bug -Â should audit like moving a client to another branch but doesnt. |
Handle center change for a group to center in same branch |
Group: group for change to center in same branch 0003-000000056Â |
Pass. |
Handle center change for a group to center in different branch |
Group: group for change to center in diff branch 0003-000000057Â |
Pass (enough). However, there is a minor mifos audit BUG where the changing of status to on-hold is not audited. |
Handle adding a group hierarchy back to a center |
Group: group going back to a center hier 0003-000000052Â |
Fail.  Connected to MIFOS-3871             |
Handle a Loan Officer change for a center |
Center: center with a LO change 0003-000000032 |
Pass. center, group & client customer entries good and associated accounts good. |
Transaction Tests
Notes:
Transactions are linked into account entries that are relevant to them at the action (or disbursal) date of the transaction - 'open' (savings), active (repayments) or pre-active (disbursals).
Requirement |
Test |
Result |
---|---|---|
All savings transactions should link to the latest savings account entry that is 'open' (active or inactive but not closed) for the date matching the transaction action_date. |
1. Deposit 100 into savings account. |
Pass. |
 |
2. On one day - deposit 100 into a savings account, make inactive, deposit another 100 (which makes it active) |
Pass. All deposits and withdraws link to the latest open (inactive in this case) entry for the savings account. |
All repayment transactions should link to the latest loan account entry that is 'active' (good or bad standing)for the date matching the transaction action_date |
1. Disburse a loan and make a repayment (or two) |
Pass. |
 |
2. Disburse a loan and make a repayment (or two) and then repay early (which closes the account). All on same day. |
Pass. |
 |
3. Disburse a loan and make a repayment (or two) and then repay early (which closes the account). Then adjust the account which reopens the loan. All on same day. |
Fail. No account_status_change_history entry was added by mifos so change from closed to active in good standing not identified. |
 |
4. Disburse a loan and make a repayment (or two). Adjust the loan to remove the last payment. |
Pass. |
 |
5. Disburse a loan and make a repayment (or two). Reverse the loan. On the same day. |
Pass. |
All write off transactions should link to the loan account entry having a loan writeoff status. |
Disburse a loan and make a repayment (or two). Then write-off the loan. On the same day. |
Pass. |
All reschedule transactions should link to the loan account entry having a loan rescheduled status. |
Disburse a loan and make a repayment (or two). Then reschedule the loan. On the same day. |
Pass. |
All disbursal transactions should link to the latest loan account entry that is pre-active - |
1. Disburse a loan and make a repayment (or two) on the same day. |
Pass. |
 |
2. Disburse a loan and make a repayment (or two). Reverse the loan. On the same day. |
Pass. |
All Customer Miscellaneous charges and penalties (that are setup on customer_schedule)Â should appear on the customer charges and fees table linked to an active or on-hold customer |
Group: Group with lots of fees  0006-000000062  |
Pass.  2 entries created on table fact_customer_fees_and_charges for the customer. The misc. fee entry had an account_charge_type_id of 2 (misc fee), and the misc. penalty had an account_charge_type_id of 3 (misc penalty). |
All Customer Fees (that are setup on customer_fee_schedule) should appear on the customer charges and fees table linked to an active or on-hold customer |
Group: Group with lots of fees  0006-000000062 |
Pass. Entries created with an account_charge_type_id of 1 (fees) |
 |
 |
 |