示例#1
0
 def test_wordCount1(self):
     self.assertEqual(wordCount.numWords("Hi"), 1)
示例#2
0
 def test_wordCount4(self):
     self.assertEqual(wordCount.numWords(10), "Not a valid string")
示例#3
0
 def test_wordCount5(self):
     self.assertEqual(wordCount.numWords("Hello World!"), 5)
示例#4
0
 def test_wordCount3(self):
     self.assertEqual(wordCount.numWords(""), 0)
def test_wordCount1():
    assert wordCount.numWords("Hi") == 1
def test_wordCount5():
    assert wordCount.numWords("Hello World!") == 5
def test_wordCount4():
    assert wordCount.numWords(10) == "Not a valid string"
def test_wordCount3():
    assert wordCount.numWords("") == 0