public void ValidInput_ShouldReturnFormattedValidInput() { //Arrange FakeDelayedFormat fakeDelayedFormatReg = new FakeDelayedFormat.Builder().Value("regex").Build(); FakeDelayedArrayFormat fakeDelayedArrayFormat = new FakeDelayedArrayFormat.Builder().Value(new[] { "sample", "blort" }).Build(); FakeValidInputResponseAction <string> fakeValidInputResponseAction = new FakeValidInputResponseAction <string> .Builder().Build(); FormattedValidInput <string> subject = new FormattedValidInput <string>(fakeDelayedFormatReg, fakeDelayedArrayFormat, fakeValidInputResponseAction); //Act IValidResponse <string> actual = subject.ValidInput(); //Assert fakeDelayedArrayFormat.AssertValueInvoked(); fakeDelayedFormatReg.AssertValueInvoked(); }
public FirstHumanCreation(IValidResponse <IPlayer> validResponse) => _validResponse = validResponse;
public GameModeSelection(IValidResponse <IGameMode> validResponse) => _validResponse = validResponse;
public Builder ValidInput(IValidResponse <T> expected) { _validInputItem.UpdateInvocation(expected); return(this); }
public HumanVsComputerGameMode(IValidResponse <IPlayerOrder> validResponse, IPlayerCreation humanCreation, IPlayerCreation computerCreation) { _validResponse = validResponse; _humanCreation = humanCreation; _computerCreation = computerCreation; }
public HumanMoveInput(IValidResponse <IGlyph> validResponse, IWriter writer) { _validResponse = validResponse; _writer = writer; }