예제 #1
0
        public void GetWord_GetWord_String()
        {
            int         total          = 0;
            string      word           = "test";
            WordCounter newWordCounter = new WordCounter(total, word, "");

            Assert.AreEqual(word, newWordCounter.GetWord());
        }
예제 #2
0
        public void ChangeToLowerCase_WordandSentence_SpecificAmount()
        {
            WordCounter testWordCounter = new WordCounter("Hi", "How are you.");

            testWordCounter.ChangeToLowerCase();
            Assert.AreEqual("hi", testWordCounter.GetWord());
            Assert.AreEqual("how are you.", testWordCounter.GetSentence());
        }
예제 #3
0
        public void SetWord_SetWord_string()
        {
            int         total          = 0;
            string      word           = "test";
            WordCounter newWordCounter = new WordCounter(total, word, "");
            string      updatedWord    = "wow";

            newWordCounter.SetWord(updatedWord);
            Assert.AreEqual(updatedWord, newWordCounter.GetWord());
        }