Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 6 additions & 3 deletions spec/system/moderator_messages_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -678,9 +678,12 @@ def navigate_to_topic(title)
expect(link[:href]).to include("/t/")
shot("95_mod_note_notification_in_user_menu")

# Found again: opening the menu marks the notifications seen, and the
# list can re-render between the checks above and the click.
find(".notification.custom a[title='Moderator note']", match: :first).click
# Opening the menu marks the notifications seen, and the list can
# re-render under a click, even one on a freshly found link. Playwright's
# locator finds the link again on each try; Capybara's element doesn't.
page.driver.with_playwright_page do |pw|
pw.locator(".notification.custom a[title='Moderator note']").first.click
end

# Clicking the notification lands on the topic — at the note, the same
# target the notes feed uses.
Expand Down
Loading