public void ShouldResetDisplayWhenCancel()
 {
     _ps.AddPayment(25);
     Assert.That(_ps.ReadDisplay(), Is.EqualTo(1010));
     _ps.Cancel();
     Assert.That(_ps.ReadDisplay(), Is.EqualTo(1000));
     _ps.AddPayment(5);
     Assert.That(_ps.ReadDisplay(), Is.EqualTo(1002));
 }
        public void AddPayment(int coinValue)
        {
            if (coinValue == 5)
            {
                _numberOfFiveCents++;
            }

            if (_numberOfFiveCents > 10)
            {
                _numberOfFiveCents = 0;
                _payStation.Cancel();
                return;
            }

            _payStation.AddPayment(coinValue);
        }
 public IDictionary <int, int> Cancel()
 {
     return(_payStation.Cancel());
 }