def test_isWordGuessed2(self):
     actual = hangman.isWordGuessed("boss", ['b', 'o', 't'])
     self.assertFalse(actual, "The word you guessed is not correct")
Example #2
0
def test_is_word_guessed():
    assert (isWordGuessed('tomato', ['t', 'o', 'x']) == False)
    assert (isWordGuessed('tomato', ['t', 'o', 'm', 'a']) == True)
 def test_isWordGuessed(self):
     actual = hangman.isWordGuessed("boss", ['b', 'o', 's'])
     self.assertTrue(actual, "The word you guessed it correct")
Example #4
0
def test_isWordGuessed(s, l, result):
    """Test isWordGuessed return correct result."""
    from hangman import isWordGuessed
    assert isWordGuessed(s, l) == result