public void TestWithdrawBasic() { Account account = new Account("Cash",100); account.Withdraw(100); Assert.AreEqual(account.GetBalance(), 0); }
public void TestDepositBasic() { Account account = new Account("Cash"); account.Deposit(100); Assert.AreEqual(account.GetBalance(), 100); }
public void TestWithdrawInsufficientFunds() { Account account = new Account("Cash", 100); try { account.Withdraw(200); } finally { Assert.AreEqual(account.GetBalance(), 100); } }
public void TestDepositNegativeAmount() { Account account = new Account("Cash"); try { account.Deposit(-100); } finally { Assert.AreEqual(account.GetBalance(), 0); } }
public void TestWithdrawNoAmount() { Account account = new Account("Cash"); account.Withdraw(0); }
public void TestDepositNoAmount() { Account account = new Account("Cash"); account.Deposit(0); }