Beispiel #1
0
 def test_one(self):
     self.assertEqual(2, count_substrings("This is a test string", "is"))
Beispiel #2
0
 def test_five(self):
     self.assertEqual(2, count_substrings("This is this and that is this", "this"))
Beispiel #3
0
 def test_three(self):
     self.assertEqual(4, count_substrings("Python is an awesome language to program in!", "o"))
Beispiel #4
0
 def test_four(self):
     self.assertEqual(0, count_substrings("We have nothing in common!", "really?"))
Beispiel #5
0
 def test_two(self):
     self.assertEqual(2, count_substrings("babababa", "baba"))