MCPcopy Index your code
hub / github.com/python/cpython / test_ratio_for_null_seqn

Method test_ratio_for_null_seqn

Lib/test/test_difflib.py:75–80  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

73
74class TestSFbugs(unittest.TestCase):
75 def test_ratio_for_null_seqn(self):
76 # Check clearing of SF bug 763023
77 s = difflib.SequenceMatcher(None, [], [])
78 self.assertEqual(s.ratio(), 1)
79 self.assertEqual(s.quick_ratio(), 1)
80 self.assertEqual(s.real_quick_ratio(), 1)
81
82 def test_comparing_empty_lists(self):
83 # Check fix for bug #979794

Callers

nothing calls this directly

Calls 4

ratioMethod · 0.95
quick_ratioMethod · 0.95
real_quick_ratioMethod · 0.95
assertEqualMethod · 0.45

Tested by

no test coverage detected