public void TestIfWordCheckerCanBeInitialized() { try { var words = new List<string>() { "testi", "äägsgdd"}; var wordChecker = new WordChecker(words); } catch (Exception ex) { Assert.Fail("Initialization of WordChecker failed. Expection information: " + ex.ToString()); } }
public void TestWordsOfDifferentLengthsReturnFalse() { var wordChecker = new WordChecker("AMassiveWord"); Assert.IsFalse(wordChecker.CheckIfDiffersByOneIndex("Yup")); }
public void TestWordsWhichDifferByMoreThanOneIndexReturnsFalse() { var wordChecker = new WordChecker("Two"); Assert.IsFalse(wordChecker.CheckIfDiffersByOneIndex("Pop")); }
public void TestWordsWhichDifferByOneIndexReturnsTrue() { var wordChecker = new WordChecker("ONE"); Assert.IsTrue(wordChecker.CheckIfDiffersByOneIndex("ONT")); }
public void IsOnlyAlphaCharacters_ChecksIfInputIsStringOfAlphaChars_False() { WordChecker testWordChecker = new WordChecker("R2D2"); Assert.AreEqual(false, testWordChecker.IsOnlyAlphaCharacters()); }
public void WordCheckerConstructor_ConstructAnInstanceOfAClass_Sparkle() { WordChecker testWordChecker = new WordChecker("Sparkle"); Assert.AreEqual("Sparkle", testWordChecker.Input); }