public void Withdraw()
        {
            var WithDrawDate = new DateTime(2020, 03, 08);

            calendarWrapper.GeteDate().Returns(WithDrawDate);
            bankAccountController.Withdraw(600);
            bankAccount.Received().Withdraw(Arg.Is <int>(x => x == 600), Arg.Is <DateTime>(d => d == WithDrawDate));
        }
Example #2
0
        public void Withdraw()
        {
            var         bankAccountController = new BankAccountController();
            MoneyParams amount            = new MoneyParams("PLN", 1000m);
            var         bankAccountHeader = bankAccountController.Withdraw(Guid.Parse("4939209E-8CAA-4722-AC0D-31A1B15462DD"), amount);

            Assert.AreEqual(bankAccountHeader.Balances.First().Amount, 0m);
            Assert.AreEqual(bankAccountHeader.Balances.First().CurrencyISOCode, "PLN");
        }