Exemple #1
0
        private static string GetSoundexCode(string text)
        {
            if (text == null)
            {
                return(null);
            }

            return(Soundex.GetCode(text));
        }
Exemple #2
0
        private static bool SoundsLike(string left, string right)
        {
            if (left == null || right == null)
            {
                return(false);
            }

            return(Soundex.GetCode(left) == Soundex.GetCode(right));
        }
 public void Soundex_ProducesCorrectResults(string expectedCode, string text)
 {
     Assert.Equal(expectedCode, Soundex.GetCode(text));
 }