コード例 #1
0
        public void ShouldDisplayMachineBalance()
        {
            machine.DepositMachineMoney(5);
            string result = ui.PerformAction(AdminMenu.Commands.ViewMachineBalance.Command);

            Assert.IsTrue(result.Contains("$5.00"));
        }
コード例 #2
0
        public void ShouldNotChangeMachineBalance()
        {
            machine.DepositMachineMoney(2.25);

            ui.PerformAction(MainMenu.Commands.AddMoney + " 1.25");
            ui.PerformAction(MainMenu.Commands.ReturnChange.Command);

            Assert.AreEqual(2.25, machine.MachineBalance);
        }