private void AddBalanceToAccount(string TextOfPhone, int BalanceToAdd) { Account Account = Repository.GetAnAccount(TextOfPhone); Repository.AddBalanceToAccount(Account, BalanceToAdd); MessageBalanceAdded(); }
public void AddInvalidBalanceTest() { Repository.AddAccount(Account); Repository.AddBalanceToAccount(Account, -25); Assert.AreEqual(0, Account.Balance); using (var MyContext = new MyContext()) { MyContext.Accounts.Attach(Account); } }