示例#1
0
 def test_append_a(self):
     mystr = BuildStr(1, 2, 3)
     mystr.append('a')
     self.assertEqual(mystr.string, 'a')
示例#2
0
 def test_find_3(self):
     mystr = BuildStr(1, 2, 3)
     mystr.string = 'bannc'
     self.assertTrue(mystr.find('bann'))
示例#3
0
 def test_pop_chars_2(self):
     mystr = BuildStr('abcdef', 2, 3)
     self.assertEqual('ef', mystr.pop_chars(4))
示例#4
0
 def test_find_2(self):
     mystr = BuildStr(1, 2, 3)
     mystr.string = 'bannc'
     self.assertFalse(mystr.find('ab'))