예제 #1
0
def test_can_show_word_with_no_guesses():
    assert word_with_guesses("bombard", []) == "_ _ _ _ _ _ _"
    assert word_with_guesses("dog", []) == "_ _ _"
예제 #2
0
def test_can_show_word_with_guesses():
    assert word_with_guesses("bombard", ['b', 'd']) == "B _ _ B _ _ D"
    assert word_with_guesses("bombard",
                             ['b', 'o', 'm', 'a', 'r', 'd']) == "B O M B A R D"
예제 #3
0
def test_can_show_word_with_bad_guesses():
    assert word_with_guesses("bombard", ['Y', 'E']) == "_ _ _ _ _ _ _"
    assert word_with_guesses("bombard", ['Y', 'E', 'B']) == "B _ _ B _ _ _"