Added tests for balances concerning multiple users & fixed bugs in corresponding balances code