Beispiel #1
0
 public void Add_one_credit_should_print_one_bankStatement()
 {
     _bankAccount.AddCredit(1000);
     _bankAccount.Print(_printer);
     Check.That(_printer.Statements.Count).Equals(1);
     Check.That(_printer.Statements[0].ToString())
     .Equals("01/01/2016 || 1000.00  ||          || 1000.00  ");
 }
Beispiel #2
0
        public void BankAccount_AddCredit_Test_Success()
        {
            _mock.Setup(x => x.AddCredit(It.IsAny <double>()));

            double amount     = 100.00;
            double balanceRes = accountMock.Balance + amount;

            double balanceUpdated = accountMock.AddCredit(amount);

            Assert.AreEqual(balanceRes, balanceUpdated);
        }