Exemplo n.º 1
0
def test_guiterist():
    john = Guitarist("John Lennon")
    assert john.name == "John Lennon"
    assert john.get_instrument() == "Guitar"
    assert john.play_solo() == "Sympathy for the Devil"
    assert john.__str__() == "John Lennon plays Guitar"
    assert john.__repr__() == "Musician(John Lennon,Guitar)"
def test_guitarist_repr():
    gildroy = Guitarist("Gildroy")
    actual = gildroy.__repr__()
    expected = "Gildroy"
    assert expected == actual