def test_computer_play_is_valid(): for _ in range(5000): play = rps.generate_computer_play() assert rps.is_valid_play(play)
def test_paper_is_valid_play(): assert rps.is_valid_play( 'paper') is True #vyhodnocujeme, že je ten výsledek přesně TRUE!
def test_random_valid_play_is_valid(): for _ in range (100): play = rps.random_play() assert rps.is_valid_play(play)
def test_scissors_is_valid_play(): assert rps.is_valid_play('scissors') is True
def test_random_play_is_always_valid(): for _ in range(1000): assert rps.is_valid_play(rps.random_play())
def test_rock_is_valid_play(): assert rps.is_valid_play( 'rock' ) is True # miesto is je možné použiť == (v tomto prípade, inak to nie je to isté)
def test_string_is_invalid_play(): assert rps.is_valid_play('abc') is False
def test_lizard_is_not_valid_play(): assert rps.is_valid_play("lizard") is False
def test_empty_play(): assert rps.is_valid_play("") is False
def test_number_is_invalid_play(): assert rps.is_valid_play(123) is False
def test_invalid_play(): assert rps.is_valid_play("kdjfla") is False
def test_rock_is_valid_play(): assert rps.is_valid_play('rock') is True #běžná syntaxe
def test_random_play_is_valid(): for _ in range(100): play = rps.random_play() assert rps.is_valid_play(play) # is True by to bylo navíc
def test_int_is_not_a_valid_play(): assert rps.is_valid_play(3) is False
def test_rock_is_valid_play(play): assert rps.is_valid_play(play) is True
def test_blbost_is_not_a_valid_play(): assert rps.is_valid_play('blbost') is False
def test_paper_is_valid_play(): assert rps.is_valid_play("paper")
def test_spock_is_not_valid_play(): assert rps.is_valid_play("spock") is False
def test_scissors_is_valid_play(): assert rps.is_valid_play("scissors")
def test_spongebob_is_invalid_play(): assert rps.is_valid_play('spongebob') is False
def test_rock_is_valid_play(): assert rps.is_valid_play("rock")
def test_spock_is_valid_play(): assert rps.is_valid_play('sock') is False
def test_invalid_play(): assert rps.is_valid_play('lizard') == False
def test_paper_is_valid_play(): assert rps.is_valid_play('paper') is True
def test_rock_is_valid_play(): assert rps.is_valid_play('rock') is True # ověří, že fce vrací přesně True
def test_lizzard_is_valid_play(): assert rps.is_valid_play('lizard') is False
def test_paper_is_valid_play(): assert rps.is_valid_play('paper') is True # 1 is True vrací False
def test_rock_is_valid_play(): assert rps.is_valid_play('rock') is True
def test_fuck_is_invalid_play(): assert rps.is_valid_play("f**k") is False