From cacb44f7bbe7b892dfd199cedf45025267ac9894 Mon Sep 17 00:00:00 2001 From: Jamil Date: Tue, 5 Aug 2025 10:53:18 -0400 Subject: [PATCH] test(portal): fix flaky acceptance auth test (#10140) Occasionally, this fails because the element is found, but not visible due to a race condition. To fix this, we assert that the element should be visible before clicking on it. Fixes https://github.com/firezone/firezone/actions/runs/16751908154/job/47424125321 --- elixir/apps/web/test/web/acceptance/auth_test.exs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/elixir/apps/web/test/web/acceptance/auth_test.exs b/elixir/apps/web/test/web/acceptance/auth_test.exs index b4084f0b9..09827ff69 100644 --- a/elixir/apps/web/test/web/acceptance/auth_test.exs +++ b/elixir/apps/web/test/web/acceptance/auth_test.exs @@ -38,7 +38,7 @@ defmodule Web.Acceptance.AuthTest do |> visit(~p"/#{account}") |> Auth.authenticate(identity) |> visit(~p"/#{account}/actors") - |> assert_el(Query.css("#user-menu-button")) + |> assert_el(Query.css("#user-menu-button", visible: true)) |> click(Query.css("#user-menu-button")) |> assert_el(Query.link("Sign out", visible: true)) |> click(Query.link("Sign out"))