public void TestEqualsTo()
        {
            Money five = new Money(5);
            Money anotherFive = new Money(5);

            Assert.AreEqual(true, five.EqualsTo(anotherFive));
        }
Esempio n. 2
0
 public bool EqualsTo(Money money)
 {
     Bank bank = new Bank();
     return this.Amount * bank.GetRate() == money.Amount;
 }
 public void TestMultiplication()
 {
     Money five = new Money(5);
     five.Times(2);
     Assert.AreEqual(10, five.Amount);
 }
 public void TestFloatAmount()
 {
     Money fivePointThree = new Money(5.3);
     Assert.AreEqual(5.3, fivePointThree.Amount);
 }