public void Test2() { using FakeConsole console = new FakeConsole("hello hello hi hello. hello, hi, hello, hello. hi hi. hi hi,,"); Program.Main(); Assert.AreEqual("The most frequent word is hi with 6 occurances.", console.Output); }
public void Test3() { using FakeConsole console = new FakeConsole(" . . . .. ,, ., .. ,. .., ., .,,"); Program.Main(); Assert.AreEqual("Could not find any words.", console.Output); }
public void Test4() { using FakeConsole console = new FakeConsole("e- -e e- e- - -"); Program.Main(); Assert.AreEqual("The most frequent word is e- with 3 occurances.", console.Output); }