Esempio n. 1
0
        public void Can_Compute_Levenshtein_Distance(string s1, string s2, int expectedDistance)
        {
            // arrange
            var service = new LevenshteinFuzzySearch();

            // act
            var actualDistance = service.ComputeSimilarity(s1, s2);

            // assert
            Assert.Equal(expectedDistance, actualDistance);
        }
 public int LevenshteinDistance() => _levenshteinFuzzySearch.ComputeSimilarity(String1.Value, String2.Value);