Exemplo n.º 1
0
Arquivo: tests.py Projeto: andyzt/tceh
    def test_unfinished_states(self):
        unfinished_state = list(range(15))
        unfinished_state.append(EMPTY_MARK)
        unfinished_state[0], unfinished_state[-1] = \
            unfinished_state[-1], unfinished_state[0]

        result = is_game_finished(unfinished_state)
        self.assert_equal(result, False)
Exemplo n.º 2
0
    def test_unfinished_states(self):
        unfinished_state = list(range(15))
        unfinished_state.append(EMPTY_MARK)
        unfinished_state[0], unfinished_state[-1] = \
            unfinished_state[-1], unfinished_state[0]

        result = is_game_finished(unfinished_state)
        self.assert_equal(result, False)
Exemplo n.º 3
0
    def test_finished_state(self):
        finished_state = list(range(15))
        finished_state.append(EMPTY_MARK)

        result = is_game_finished(finished_state)
        self.assert_equal(result, True)
Exemplo n.º 4
0
Arquivo: tests.py Projeto: andyzt/tceh
    def test_finished_state(self):
        finished_state = list(range(15))
        finished_state.append(EMPTY_MARK)

        result = is_game_finished(finished_state)
        self.assert_equal(result, True)