public void RentProductCommandInterpreter_NotHandleAnotherKey()
        {
            //Arrange
            var driver = A.Fake<IInputOutputDriver>();
            var rentService = A.Fake<IAppRentService>();
            A.CallTo(() => driver.Input()).Returns(A.Dummy<string>());
            A.CallTo(() => rentService.RentProduct(A<string>.Ignored, A<string>.Ignored)).Returns(new OperationMessage() { Succeed = true, Message = A.Dummy<string>() });
            var sut = new RentProductCommandInterpreter(driver, rentService);

            //Act
            var res = sut.HandleCommand(Constants.AnotherKey);

            //Assert
            res.HasSucceed.Should().BeFalse();
            res.IsTerminating.Should().BeFalse();
            res.Message.Should().Be(UI.Properties.Resources.CommandUnrecognized);
        }
        public void RentProductCommandInterpreter_ResistAppServiceFailure()
        {
            //Arrange
            var driver = A.Fake<IInputOutputDriver>();
            var rentService = A.Fake<IAppRentService>();
            var expectedMessage = "Expected";
            A.CallTo(() => driver.Input()).Returns(A.Dummy<string>());
            A.CallTo(() => rentService.RentProduct(A<string>.Ignored, A<string>.Ignored)).Throws(new Exception(expectedMessage));
            var sut = new RentProductCommandInterpreter(driver, rentService);

            //Act
            var res = sut.HandleCommand(Challenge3.UI.Commands.Constants.RentKey);

            //Assert
            res.HasSucceed.Should().BeFalse();
            res.IsTerminating.Should().BeFalse();
            res.Message.Should().Be(expectedMessage);
        }