Example #1
0
 def test_mismatch_cases(self):
     self.assertEqual(stringdiff.score('asdf', 'ASDF'), 0)
Example #2
0
 def test_match_equal(self):
     self.assertEqual(stringdiff.score('asdf', 'asdf'), 1)
Example #3
0
 def test_score_kitten_sitting(self):
     self.assertEqual(stringdiff.score('kitten', 'sitting'), 4 / 7)
Example #4
0
 def test_score_weekdays(self):
     self.assertEqual(stringdiff.score('Saturday', 'Sunday'), 5 / 8)
Example #5
0
 def test_match_equal_ignoring_case(self):
     self.assertEqual(
         stringdiff.score('asdf', 'ASDF', case_sensitive=False),
         1,
     )