예제 #1
0
 def test_fullpartdoubleresult(self):
     s1 = "de"
     s2 = "abcdedef"
     ss = sharedlengthnsubstrings(s1=s1, s2=s2, n=2, readingframe=1)
     self.assertEqual(ss, ((('de', (
         (0, 3),
         (0, 5),
     )), )))
예제 #2
0
 def test_partfulldoubleresult(self):
     s1 = "fdeg"
     s2 = "dede"
     ss = sharedlengthnsubstrings(s1=s1, s2=s2, n=2, readingframe=1)
     self.assertEqual(ss, ((('de', (
         (1, 0),
         (1, 2),
     )), )))
예제 #3
0
 def test_readingframe2(self):
     s1 = "cdefgi"
     s2 = "abcdefgh"
     ss = sharedlengthnsubstrings(s1=s1, s2=s2, n=2, readingframe=2)
     self.assertEqual(ss, ((('cdef', ((0, 1),)),)))
예제 #4
0
 def test_partfulldoubleresult(self):
     s1 = "fdeg"
     s2 = "dede"
     ss = sharedlengthnsubstrings(s1=s1, s2=s2, n=2, readingframe=1)
     self.assertEqual(ss, ((('de', ((1, 0), (1, 2),)),)))
예제 #5
0
 def test_fullpartsingleresult(self):
     s1 = "bc"
     s2 = "abcde"
     ss = sharedlengthnsubstrings(s1=s1, s2=s2, n=2, readingframe=1)
     self.assertEqual(ss, ((('bc'),((0, 1),)),))
예제 #6
0
 def test_fullpartdoubleresult(self):
     s1 = "de"
     s2 = "abcdedef"
     ss = sharedlengthnsubstrings(s1=s1, s2=s2, n=2, readingframe=1)
     self.assertEqual(ss, ((('de', ((0, 3), (0, 5),)),)))
예제 #7
0
 def test_partfullsingleresultend(self):
     s1 = "fgde"
     s2 = "de"
     ss = sharedlengthnsubstrings(s1=s1, s2=s2, n=2, readingframe=1)
     self.assertEqual(ss, ((('de'), ((2, 0),)),))
예제 #8
0
 def test_partfullsingleresultstart(self):
     s1 = "abgf"
     s2 = "ab"
     ss = sharedlengthnsubstrings(s1=s1, s2=s2, n=2, readingframe=1)
     self.assertEqual(ss, ((('ab'), ((0, 0),)),))
예제 #9
0
 def test_partfullsingleresult(self):
     s1 = "fbcg"
     s2 = "bc"
     ss = sharedlengthnsubstrings(s1=s1, s2=s2, n=2, readingframe=1)
     self.assertEqual(ss, ((('bc'), ((1, 0),)),))
예제 #10
0
 def test_partpartsingleresultend(self):
     s1 = "fdeg"
     s2 = "abcde"
     ss = sharedlengthnsubstrings(s1=s1, s2=s2, n=2, readingframe=1)
     self.assertEqual(ss, ((('de'), ((1, 3),)),))
예제 #11
0
 def test_readingframe2(self):
     s1 = "cdefgi"
     s2 = "abcdefgh"
     ss = sharedlengthnsubstrings(s1=s1, s2=s2, n=2, readingframe=2)
     self.assertEqual(ss, ((('cdef', ((0, 1), )), )))
예제 #12
0
 def test_fullpartsingleresult(self):
     s1 = "bc"
     s2 = "abcde"
     ss = sharedlengthnsubstrings(s1=s1, s2=s2, n=2, readingframe=1)
     self.assertEqual(ss, ((('bc'), ((0, 1), )), ))
예제 #13
0
 def test_partfullsingleresultend(self):
     s1 = "fgde"
     s2 = "de"
     ss = sharedlengthnsubstrings(s1=s1, s2=s2, n=2, readingframe=1)
     self.assertEqual(ss, ((('de'), ((2, 0), )), ))
예제 #14
0
 def test_partfullsingleresultstart(self):
     s1 = "abgf"
     s2 = "ab"
     ss = sharedlengthnsubstrings(s1=s1, s2=s2, n=2, readingframe=1)
     self.assertEqual(ss, ((('ab'), ((0, 0), )), ))
예제 #15
0
 def test_partfullsingleresult(self):
     s1 = "fbcg"
     s2 = "bc"
     ss = sharedlengthnsubstrings(s1=s1, s2=s2, n=2, readingframe=1)
     self.assertEqual(ss, ((('bc'), ((1, 0), )), ))
예제 #16
0
 def test_partpartsingleresultend(self):
     s1 = "fdeg"
     s2 = "abcde"
     ss = sharedlengthnsubstrings(s1=s1, s2=s2, n=2, readingframe=1)
     self.assertEqual(ss, ((('de'), ((1, 3), )), ))