public void FirstObjectCountTest() { WordCountHelper helper = new WordCountHelper(); List <WordCount> actual = helper.WordsCountList("Blue is Blue"); Assert.IsTrue(actual.Count() == 2); Assert.IsTrue(actual[0].Count == 2); }
public void ListsCountTest() { WordCountHelper helper = new WordCountHelper(); IList <WordCount> expected = new List <WordCount>(); expected.Add(new WordCount() { Word = "Taco", Count = 3 }); List <WordCount> actual = helper.WordsCountList("Taco Taco taco"); Assert.AreEqual(expected.Count(), actual.Count()); Assert.IsTrue(actual[0].Count == 3); }