test: adapt earlier tests to groups implementation
Some checks failed
continuous-integration/drone/push Build is failing
Some checks failed
continuous-integration/drone/push Build is failing
This commit is contained in:
parent
3b87db6ad1
commit
3322efcdf6
4 changed files with 50 additions and 85 deletions
|
|
@ -86,7 +86,7 @@ defmodule MvWeb.MemberLive.IndexGroupsAccessibilityTest do
|
|||
# Verify sort header has aria-label
|
||||
# Sort header should have aria-label describing the sort state
|
||||
assert html =~ ~r/aria-label=.*[Gg]roup/ or
|
||||
has_element?(view, "[data-testid='sort_groups'][aria-label]")
|
||||
has_element?(view, "[data-testid='groups'][aria-label]")
|
||||
end
|
||||
|
||||
@tag :ui
|
||||
|
|
@ -106,7 +106,7 @@ defmodule MvWeb.MemberLive.IndexGroupsAccessibilityTest do
|
|||
# Test that dropdown can be focused and changed via keyboard
|
||||
# (This is a basic accessibility check - actual keyboard testing would require browser automation)
|
||||
view
|
||||
|> element("select[name='group_filter']")
|
||||
|> element("#group-filter-form")
|
||||
|> render_change(%{"group_filter" => group1.id})
|
||||
|
||||
# Verify change was applied
|
||||
|
|
@ -124,11 +124,11 @@ defmodule MvWeb.MemberLive.IndexGroupsAccessibilityTest do
|
|||
# Verify sort header is keyboard accessible
|
||||
# Tab should focus the sort header
|
||||
# Enter/Space should activate sorting
|
||||
assert has_element?(view, "[data-testid='sort_groups']")
|
||||
assert has_element?(view, "[data-testid='groups']")
|
||||
|
||||
# Test that sort header can be activated via click (simulating keyboard)
|
||||
view
|
||||
|> element("[data-testid='sort_groups']")
|
||||
|> element("[data-testid='groups']")
|
||||
|> render_click()
|
||||
|
||||
# Verify sort was applied
|
||||
|
|
@ -146,7 +146,7 @@ defmodule MvWeb.MemberLive.IndexGroupsAccessibilityTest do
|
|||
|
||||
# Apply filter
|
||||
view
|
||||
|> element("select[name='group_filter']")
|
||||
|> element("#group-filter-form")
|
||||
|> render_change(%{"group_filter" => group1.id})
|
||||
|
||||
# Verify filter change is announced (via aria-live region or similar)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue