public void TestCrediterCompte(int somme, int result) { AccountUser myUser = new AccountUser("FX", "Fabre", "chez moi"); myUser.CreateAccount("compte 1"); myUser.CrediterCompte(somme); Assert.AreEqual(result, myUser.SoldeCompte()); }
public void TestDisplayOperations() { AccountUser myUser = new AccountUser("FX", "Fabre", "chez moi"); myUser.CreateAccount("compte 1"); for (int i = 1; i <= 30; ++i) { myUser.DebiterCompte(i); } Console.WriteLine(myUser.DisplayOperations()); Assert.AreEqual(-15 * 31, myUser.SoldeCompte()); }