Visa Inc. interview question

write jUnit for the same and mock db call