public void UserWord_GetWord_True() { //Arrange string newWord = "pizza"; words newWords = new words(); //Act newWords.SetWord(newWord); string result = newWords.GetWord(); //Assert Assert.AreEqual(result, newWord); }
public void UserParagraph_Compare_True() { //Arrange string newWord = "pizza"; string newParagraph = "oh boy, i sure love pizza"; words newWords = new words(); //Act newWords.SetWord(newWord); newWords.SetParagraph(newParagraph); string testWord = newWords.GetWord(); string[] testPara = newWords.Split(); int result = newWords.Compare(testWord, testPara); //Assert Assert.AreEqual(result, 1); }