DEV: Remove assertion causing test to be flaky (#25069)

Why this change?

The assertion does not make use of Capybara's waiting strategy and is
not really testing anything meaningful by asserting for the src of the
img element.
This commit is contained in:
Alan Guo Xiang Tan 2023-12-29 13:23:16 +08:00 committed by GitHub
parent c6cb319671
commit ea910e291b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 2 deletions

View File

@ -25,10 +25,10 @@ RSpec.describe "User status | sidebar", type: :system do
context "when changing status" do
it "updates status" do
visit("/")
current_user.set_status!("offline", "tooth")
expect(page).to have_css('.user-status-message .emoji[alt="tooth"]')
expect(find(".user-status-message .emoji")["src"]).to include("tooth")
expect(page).to have_css('.user-status-message img.emoji[alt="tooth"]')
end
end