public void CountCharTest() { string str = "Hello world!I am a boy."; int count = str.Length; Assert.AreEqual(TXtOperate.CountChar(str), count); string str1 = ""; Assert.AreEqual(TXtOperate.CountChar(str1), str1.Length); //Assert.Fail(); }