コード例 #1
0
 def test_common_spans(self):
     for a, b, expected in [
         ('an exact match', 'an exact match', [14]),
         ('some example string', 'some other string', [5, 7, 7]),
         ('a problem with a common set', 'a common set', [2, 7, 1, 4, 13]),
     ]:
         self.assertEqual(summarize.common_spans([a, b]), expected)
コード例 #2
0
ファイル: summarize_test.py プロジェクト: MHBauer/test-infra
 def test_common_spans(self):
     for a, b, expected in [
             ('an exact match', 'an exact match', [14]),
             ('some example string', 'some other string', [5, 7, 7]),
             ('a problem with a common set', 'a common set', [2, 7, 1, 4, 13]),
     ]:
         self.assertEqual(summarize.common_spans([a, b]), expected)