Esempio n. 1
0
def test_resolving_score_from_many_tiles_to_the_right():
    tile_wall = TileWall()
    tile_wall.add_tile_to_tile_wall(3, "blue")
    tile_wall.add_tile_to_tile_wall(3, "yellow")
    tile_wall.add_tile_to_tile_wall(3, "red")
    tile_wall.add_tile_to_tile_wall(3, "teal")
    assert tile_wall.score == 10
Esempio n. 2
0
def test_resolving_score_from_many_tiles_below():
    tile_wall = TileWall()
    tile_wall.add_tile_to_tile_wall(3, "blue")
    tile_wall.add_tile_to_tile_wall(4, "teal")
    tile_wall.add_tile_to_tile_wall(5, "black")
    tile_wall.add_tile_to_tile_wall(2, "yellow")
    assert tile_wall.score == 10
Esempio n. 3
0
def test_resolving_score_from_tile_with_no_tiles_next_to_it():
    tile_wall = TileWall()
    tile_wall.add_tile_to_tile_wall(3, "blue")
    assert tile_wall.score == 1
Esempio n. 4
0
def test_resolving_score_from_one_tile_the_left_and_one_tile_to_the_right():
    tile_wall = TileWall()
    tile_wall.add_tile_to_tile_wall(3, "teal")
    tile_wall.add_tile_to_tile_wall(3, "yellow")
    tile_wall.add_tile_to_tile_wall(3, "blue")
    assert tile_wall.score == 5
Esempio n. 5
0
def test_add_tile_to_tile_wall():
    tile_wall = TileWall()
    tile_wall.add_tile_to_tile_wall(1, "red")
    assert tile_wall.tile_wall[0].get_slot_by_color("red").filled
Esempio n. 6
0
def test_resolving_score_stops_on_blank_space_row():
    tile_wall = TileWall()
    assert tile_wall.add_tile_to_tile_wall(3, "teal") == 1
    assert tile_wall.add_tile_to_tile_wall(3, "black") == 2
    assert tile_wall.add_tile_to_tile_wall(3, "yellow") == 1
    assert tile_wall.score == 4
Esempio n. 7
0
def test_resolving_score_from_one_tile_below_and_one_tile_above():
    tile_wall = TileWall()
    tile_wall.add_tile_to_tile_wall(2, "yellow")
    tile_wall.add_tile_to_tile_wall(4, "teal")
    tile_wall.add_tile_to_tile_wall(3, "blue")
    assert tile_wall.score == 5
Esempio n. 8
0
def test_resolving_score_stops_on_blank_space_column():
    tile_wall = TileWall()
    assert tile_wall.add_tile_to_tile_wall(1, "blue") == 1
    assert tile_wall.add_tile_to_tile_wall(2, "teal") == 2
    assert tile_wall.add_tile_to_tile_wall(4, "red") == 1
    assert tile_wall.score == 4
Esempio n. 9
0
def test_resolving_score_from_one_tile_below():
    tile_wall = TileWall()
    tile_wall.add_tile_to_tile_wall(3, "blue")
    tile_wall.add_tile_to_tile_wall(2, "yellow")
    assert tile_wall.score == 3
Esempio n. 10
0
def test_resolving_score_from_tiles_left_right_above_below():
    tile_wall = TileWall()
    tile_wall.add_tile_to_tile_wall(3, "teal")
    tile_wall.add_tile_to_tile_wall(3, "yellow")
    tile_wall.add_tile_to_tile_wall(4, "teal")
    tile_wall.add_tile_to_tile_wall(2, "yellow")
    tile_wall.add_tile_to_tile_wall(3, "blue")
    assert tile_wall.score == 10
Esempio n. 11
0
def test_resolving_score_from_one_tile_the_right_and_one_tile_on_bottom():
    tile_wall = TileWall()
    tile_wall.add_tile_to_tile_wall(1, "yellow")
    tile_wall.add_tile_to_tile_wall(2, "teal")
    tile_wall.add_tile_to_tile_wall(1, "blue")
    assert tile_wall.score == 6
Esempio n. 12
0
def test_resolving_score_from_one_tile_the_right_and_one_tile_on_top():
    tile_wall = TileWall()
    tile_wall.add_tile_to_tile_wall(5, "red")
    tile_wall.add_tile_to_tile_wall(4, "red")
    tile_wall.add_tile_to_tile_wall(5, "yellow")
    assert tile_wall.score == 6