Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix: multiwiki_assignment_spec failure #6088

Closed
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
3 changes: 2 additions & 1 deletion spec/features/multiwiki_assignment_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -60,8 +60,9 @@
first('textarea').set(
"Terre\nhttps://fr.wikipedia.org/wiki/Anglais"
)
expect(page).to have_button('Assign all')
click_button 'Assign all'
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think this will make a difference, as click_button already incorporates Capybara 'wait' behavior. If the button renders in time, it will work either way, and if it takes more than the wait time to render, it will fail at the expect(page)...

Copy link
Contributor Author

@Formasitchijoh Formasitchijoh Jan 4, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Your right, I thought ensuring the button is found within the #user element, before it is interacted with
when i tested locally running Capybara in headless mode i realized the Assign all button appeared and close very fast

end
click_button 'Assign all'

visit "/courses/#{course.slug}/students/articles"
first('.student-selection .student').click
Expand Down
Loading