예제 #1
0
        public void FullWordsOnly_0()
        {
            RepeatCounter newCounter = new RepeatCounter("brain", "brainstorm");
            int           output     = newCounter.characterCount();

            Assert.AreEqual(0, output);
        }
예제 #2
0
        public void NoSpecialCharactersOrPunctuation_3()
        {
            RepeatCounter newCounter = new RepeatCounter("brain", "The brain is like a muscle I like to call super brain and it goes to the brain gym.");
            int           output     = newCounter.characterCount();

            Assert.AreEqual(3, output);
        }
예제 #3
0
        public void PunctuationInSentence_3()
        {
            RepeatCounter newCounter = new RepeatCounter("brain", "The brain, like a muscle, needs a brain workout, good brain care and rest!");
            int           output     = newCounter.characterCount();

            Assert.AreEqual(3, output);
        }
예제 #4
0
        public void Count_WordCounterSpecialCharacters_3()
        {
            RepeatCounter newCounter = new RepeatCounter("brain", "The brain is like a muscle, a strong one I like to call super brain, but it needs brain care. | The word 'brain' appears 3 time(s) in your sentence.");
            int           output     = newCounter.characterCount();

            Assert.AreEqual(3, output);
        }