Skip to content

DEV: fix broken spec #84

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

Merged
merged 1 commit into from
May 9, 2025
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
16 changes: 9 additions & 7 deletions spec/system/kanban_functionality_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -42,13 +42,14 @@ def tagged_topic(*tags)
mode_chooser = PageObjects::Components::SelectKit.new(".kanban-mode-chooser")
mode_chooser.expand
mode_chooser.select_row_by_value("tags")

mode_chooser = PageObjects::Components::SelectKit.new(".kanban-tag-chooser")
mode_chooser.expand
mode_chooser.select_row_by_value("active")
mode_chooser.select_row_by_value("backlog")
mode_chooser.collapse

tag_chooser = PageObjects::Components::SelectKit.new(".kanban-tag-chooser")
tag_chooser.expand
tag_chooser.select_row_by_value("active")
tag_chooser.select_row_by_value("backlog")
tag_chooser.collapse

find(".kanban-modal .btn-primary").click

expect(page).to have_css(".discourse-kanban-list", count: 2)
Expand All @@ -62,8 +63,9 @@ def tagged_topic(*tags)
expect(active_list).to have_css(".topic-card", count: 2)
expect(backlog_list).to have_css(".topic-card", count: 2)

active_list.find("[data-topic-id='#{chat_active.id}']").drag_to(backlog_list)

card = active_list.find("[data-topic-id='#{chat_active.id}']")
page.execute_script("arguments[0].scrollIntoView();", card)
card.drag_to(backlog_list)
find(".dialog-content .btn-primary").click

expect(active_list).to have_css(".topic-card", count: 1)
Expand Down