public void GivenGoWordsAreFound_ThenWordValidatorIsCalledWithAllGoWords() { GivenCandidateWithPattern("a???e"); GivenMainWords("apple"); GivenGoWordsForMainWord("apple", "apple", "ape", "eel"); GivenWordsAreInTheDictionary("apple", "ape", "eel"); WhenHandleGo(); wordValidator.Received().IsWord("apple"); wordValidator.Received().IsWord("ape"); wordValidator.Received().IsWord("eel"); }
public void GivenAMessage_ThenWordValidatorIsCalled() { var message = new IsWordRequestMessage() { Word = "plus" }; requestHandler.IsWord(message); wordValidator.Received(1).IsWord("plus"); }