def test_good_case2(self): s = r''' 0 1 0 0 1 2 0 0 1 1 0 0 2 ''' fsa = k2host.str_to_fsa(s) self.assertTrue(k2host.has_self_loops(fsa))
def test_bad_cases1(self): s = r''' 0 1 0 0 0 2 0 0 1 2 0 0 2 ''' fsa = k2host.str_to_fsa(s) self.assertFalse(k2host.has_self_loops(fsa))
def test_bad_cases2(self): # empty fsa array_size = k2host.IntArray2Size(0, 0) fsa = k2host.Fsa.create_fsa_with_size(array_size) self.assertFalse(k2host.has_self_loops(fsa))