def test_winner_ended():
    text = """\
OX.
XOO
XXO
"""
    expected_is_ended = True
    board = TicTacToeState(text)
    is_ended = board.is_ended()

    assert is_ended == expected_is_ended
def test_draw_ended():
    text = """\
OXX
XOO
XOX
"""
    expected_is_ended = True
    board = TicTacToeState(text)
    is_ended = board.is_ended()

    assert is_ended == expected_is_ended
def test_not_ended():
    text = """\
OX.
XOO
XOX
"""
    expected_is_ended = False
    board = TicTacToeState(text)
    is_ended = board.is_ended()

    assert is_ended == expected_is_ended