mirror of
https://github.com/danbee/chess
synced 2025-03-04 08:39:06 +00:00
Possible random failure fix
Did swapping these two lines fix it? I need to keep and eye on this and investigate if it fails again.
This commit is contained in:
parent
743f6d3095
commit
5fce02feb5
@ -22,15 +22,14 @@ defmodule Chess.MovesTest do
|
|||||||
|> select("game[opponent_id]", option: "Zelda")
|
|> select("game[opponent_id]", option: "Zelda")
|
||||||
|> click(button("Create game"))
|
|> click(button("Create game"))
|
||||||
|
|
||||||
session
|
|
||||||
|> click(css("#f4-r1"))
|
|> click(css("#f4-r1"))
|
||||||
|> assert_has(square_selected("f4-r1"))
|
|> assert_has(square_selected("f4-r1"))
|
||||||
|> assert_has(square_containing("f4-r1", "white.pawn"))
|
|> assert_has(square_containing("f4-r1", "white.pawn"))
|
||||||
|
|
||||||
session
|
# TODO: Random failure, Investigate!
|
||||||
|> click(css("#f4-r3"))
|
|> click(css("#f4-r3"))
|
||||||
|> refute_has(square_containing("f4-r1", "white.pawn"))
|
|
||||||
|> assert_has(square_containing("f4-r3", "white.pawn"))
|
|> assert_has(square_containing("f4-r3", "white.pawn"))
|
||||||
|
|> refute_has(square_containing("f4-r1", "white.pawn"))
|
||||||
end
|
end
|
||||||
|
|
||||||
test "cannot move the opponents pieces", %{session: session} do
|
test "cannot move the opponents pieces", %{session: session} do
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user