OpenProject is the leading open source project management software for product, project and portfolio management. A powerful Jira alternative with agile planning, issue tracking, roadmaps, Gantt charts, time tracking, collaboration features, and more. Available on premises or in the cloud. ⭐ Star us on GitHub
Ruby agile-developmentangularbcfboardsbug-trackerganttgantt-chartifcissue-trackerjira-alternativekanbanopenprojectproduct-managementproject-managementproject-planningroadmaprubyscrumtimelineworkflows
attempt to fix flickering activity specs
ulfertsfa7381d2ef6f
diff --git a/spec/features/activities/work_package/activities_spec.rb b/spec/features/activities/work_package/activities_spec.rbindex 681a67709f4..0f38ad717f3 100644--- a/spec/features/activities/work_package/activities_spec.rb+++ b/spec/features/activities/work_package/activities_spec.rb@@ -250,7 +250,7 @@ RSpec.describe "Work package activity", :js, :with_cuprite dowp_page.wait_for_activity_tabend- it "shows and merges activities and comments correctly", :aggregate_failures do+ it "shows and merges activities and comments correctly" dofirst_journal = work_package.journals.first# initial journal entry is shown without changeset or comment@@ -330,7 +330,7 @@ RSpec.describe "Work package activity", :js, :with_cuprite dowp_page.wait_for_activity_tabend- it "shows and merges activities and comments correctly", :aggregate_failures do+ it "shows and merges activities and comments correctly" dofirst_journal = work_package.journals.first# initial journal entry is shown without changeset or comment@@ -398,7 +398,7 @@ RSpec.describe "Work package activity", :js, :with_cuprite doENV.delete("WORK_PACKAGES_ACTIVITIES_TAB_POLLING_INTERVAL_IN_MS")end- it "shows the comment of another user without browser reload", :aggregate_failures do+ it "shows the comment of another user without browser reload" do# simulate member creating a commentfirst_journal = create(:work_package_journal,user: member,@@ -494,7 +494,7 @@ RSpec.describe "Work package activity", :js, :with_cuprite dowp_page.wait_for_activity_tabend- it "filters the activities based on type", :aggregate_failures do+ it "filters the activities based on type" do# add a non-comment journal entry by changing the work package attributeswp_page.update_attributes(subject: "A new subject") # rubocop:disable Rails/ActiveRecordAliaseswp_page.expect_and_dismiss_toaster(message: "Successful update.")@@ -560,7 +560,7 @@ RSpec.describe "Work package activity", :js, :with_cuprite doendend- it "resets an only_changes filter if a comment is added by the user", :aggregate_failures do+ it "resets an only_changes filter if a comment is added by the user" doactivity_tab.filter_journals(:only_changes)# expect only the changes@@ -585,7 +585,7 @@ RSpec.describe "Work package activity", :js, :with_cuprite dowp_page.wait_for_activity_tabend- it "focuses the editor", :aggregate_failures do+ it "focuses the editor" doactivity_tab.set_journal_sorting(:desc)activity_tab.open_new_comment_editor@@ -617,7 +617,7 @@ RSpec.describe "Work package activity", :js, :with_cuprite dowp_page.wait_for_activity_tabend- it "sorts the activities based on the sorting preference", :aggregate_failures do+ it "sorts the activities based on the sorting preference" do# expect the default sorting to be ascactivity_tab.expect_comments_order([@@ -695,13 +695,13 @@ RSpec.describe "Work package activity", :js, :with_cuprite dowp_page.wait_for_activity_tabend- it "shows the notification bubble", :aggregate_failures do+ it "shows the notification bubble" doactivity_tab.within_journal_entry(journal_mentioning_admin) doactivity_tab.expect_notification_bubbleendend- it "removes the notification bubble after the comment is read", :aggregate_failures do+ it "removes the notification bubble after the comment is read" donotificaton_for_admin.update!(read_ian: true)wp_page.visit!@@ -721,7 +721,7 @@ RSpec.describe "Work package activity", :js, :with_cuprite dowp_page.wait_for_activity_tabend- it "does not show the notification bubble", :aggregate_failures do+ it "does not show the notification bubble" doactivity_tab.within_journal_entry(journal_mentioning_admin) doactivity_tab.expect_no_notification_bubbleend@@ -746,7 +746,7 @@ RSpec.describe "Work package activity", :js, :with_cuprite dowp_page.wait_for_activity_tabend- it "can edit own comments", :aggregate_failures do+ it "can edit own comments" do# edit own commentactivity_tab.edit_comment(first_comment_by_admin, text: "First comment by admin edited")@@ -782,7 +782,7 @@ RSpec.describe "Work package activity", :js, :with_cuprite dowp_page.wait_for_activity_tabend- it "can quote other user's comments", :aggregate_failures do+ it "can quote other user's comments" do# quote other user's commentactivity_tab.quote_comment(first_comment_by_member)@@ -799,7 +799,7 @@ RSpec.describe "Work package activity", :js, :with_cuprite dowp_page.wait_for_activity_tabend- it "can quote other user's comments", :aggregate_failures do+ it "can quote other user's comments" do# open the editor and type somethingactivity_tab.type_comment("Partial message:")@@ -823,7 +823,7 @@ RSpec.describe "Work package activity", :js, :with_cuprite dowp_page.wait_for_activity_tabend- it "rescues the editor content when navigating to another workpackage tab", :aggregate_failures do+ it "rescues the editor content when navigating to another workpackage tab" do# add a comment, but do not save itactivity_tab.add_comment(text: "First comment by admin", save: false)@@ -843,7 +843,7 @@ RSpec.describe "Work package activity", :js, :with_cuprite doactivity_tab.expect_journal_notes(text: "First comment by admin")end- it "scopes the rescued content to the work package", :aggregate_failures do+ it "scopes the rescued content to the work package" do# add a comment to the first work package, but do not save itactivity_tab.add_comment(text: "First comment by admin", save: false)@@ -865,7 +865,7 @@ RSpec.describe "Work package activity", :js, :with_cuprite doendend- it "scopes the rescued content to the user", :aggregate_failures do+ it "scopes the rescued content to the user" do# add a comment to the first work package, but do not save itactivity_tab.add_comment(text: "First comment by admin", save: false)@@ -925,7 +925,7 @@ RSpec.describe "Work package activity", :js, :with_cuprite dowp_page.wait_for_activity_tabend- it "scrolls to the comment specified in the URL", :aggregate_failures do+ it "scrolls to the comment specified in the URL" dowait_for_auto_scrolling_to_finishactivity_tab.expect_journal_container_at_position(50) # would be at the bottom if no anchor would be provided@@ -939,7 +939,7 @@ RSpec.describe "Work package activity", :js, :with_cuprite dowp_page.wait_for_activity_tabend- it "scrolls to the comment specified in the URL", :aggregate_failures do+ it "scrolls to the comment specified in the URL" dowait_for_auto_scrolling_to_finishactivity_tab.expect_journal_container_at_position(50) # would be at the bottom if no anchor would be provided@@ -959,7 +959,7 @@ RSpec.describe "Work package activity", :js, :with_cuprite dowp_page.wait_for_activity_tabend- it "scrolls to the comment specified in the URL", :aggregate_failures do+ it "scrolls to the comment specified in the URL" dowait_for_auto_scrolling_to_finishactivity_tab.expect_journal_container_at_position(50) # would be at the bottom if no anchor would be provided@@ -981,7 +981,7 @@ RSpec.describe "Work package activity", :js, :with_cuprite dowp_page.wait_for_activity_tabend- it "scrolls to the comment specified in the URL", :aggregate_failures do+ it "scrolls to the comment specified in the URL" dowait_for_auto_scrolling_to_finishactivity_tab.expect_journal_container_at_bottom # would be at the top if no anchor would be provided@@ -995,7 +995,7 @@ RSpec.describe "Work package activity", :js, :with_cuprite dowp_page.wait_for_activity_tabend- it "scrolls to the comment specified in the URL", :aggregate_failures do+ it "scrolls to the comment specified in the URL" dowait_for_auto_scrolling_to_finishactivity_tab.expect_journal_container_at_bottom # would be at the top if no anchor would be provided@@ -1020,7 +1020,7 @@ RSpec.describe "Work package activity", :js, :with_cuprite doendcontext "when on desktop" do- it "scrolls to the bottom when the newest journal entry is on the bottom", :aggregate_failures do+ it "scrolls to the bottom when the newest journal entry is on the bottom" dosleep 1 # wait for auto scrolling to finishactivity_tab.expect_journal_container_at_bottom@@ -1055,7 +1055,7 @@ RSpec.describe "Work package activity", :js, :with_cuprite dowp_page.wait_for_activity_tabend- it "does not scroll to the bottom when the newest journal entry is on the bottom", :aggregate_failures do+ it "does not scroll to the bottom when the newest journal entry is on the bottom" dosleep 1 # wait for a potential auto scrolling to finish# expect activity tab not to be visibe, as the page is not scrolled to the bottomscroll_position = page.evaluate_script("document.querySelector(\"#content-body\").scrollTop")@@ -1078,7 +1078,7 @@ RSpec.describe "Work package activity", :js, :with_cuprite do# the scroll position is at around 700, some other part of the frontend code seems to trigger a scroll# happens for the files tab as well for example#- it "does not scroll to the bottom when the newest journal entry is on the bottom", :aggregate_failures do+ it "does not scroll to the bottom when the newest journal entry is on the bottom" dopending "bug/59916-on-narrow-screens-(including-mobile)-the-view-always-scrolls-to-the-activity"sleep 1 # wait for a potential auto scrolling to finish@@ -1097,7 +1097,7 @@ RSpec.describe "Work package activity", :js, :with_cuprite dowp_page.wait_for_activity_tabend- it "does not scroll to the bottom as the newest journal entry is on the top", :aggregate_failures do+ it "does not scroll to the bottom as the newest journal entry is on the top" dosleep 1 # wait for auto scrolling to finishactivity_tab.expect_journal_container_at_topend@@ -1113,7 +1113,7 @@ RSpec.describe "Work package activity", :js, :with_cuprite dolet(:editor) { Components::WysiwygEditor.new }context "if work package attachments are deactivated in project" do- it "shows the inline image and have it uploaded to the work package", :aggregate_failures do+ it "shows the inline image and have it uploaded to the work package" dologin_as adminwp_page.visit!@@ -1149,7 +1149,7 @@ RSpec.describe "Work package activity", :js, :with_cuprite dowp_page.wait_for_activity_tabend- it "shows rectracted journal entries", :aggregate_failures do+ it "shows rectracted journal entries" doactivity_tab.within_journal_entry(second_comment_by_admin) doexpect(page).to have_text(I18n.t(:"journals.changes_retracted"))end@@ -1176,7 +1176,7 @@ RSpec.describe "Work package activity", :js, :with_cuprite doENV.delete("WORK_PACKAGES_ACTIVITIES_TAB_POLLING_INTERVAL_IN_MS")end- it "shows the updated work package attribute without reload", :aggregate_failures do+ it "shows the updated work package attribute without reload" dousing_session(:admin) dologin_as(admin)@@ -1203,7 +1203,7 @@ RSpec.describe "Work package activity", :js, :with_cuprite doendend- it "shows the updated work package attribute without reload after switching back to the activity tab", :aggregate_failures do+ it "shows the updated work package attribute without reload after switching back to the activity tab" dousing_session(:admin) dologin_as(admin)@@ -1264,8 +1264,7 @@ RSpec.describe "Work package activity", :js, :with_cuprite doENV.delete("WORK_PACKAGES_ACTIVITIES_TAB_POLLING_INTERVAL_IN_MS")end- it "raises a conflict warning when the work package is updated by another user while the current user is editing",- :aggregate_failures do+ it "raises a conflict warning when the work package is updated by another user while the current user is editing" dousing_session(:admin) dologin_as(admin)@@ -1304,8 +1303,7 @@ RSpec.describe "Work package activity", :js, :with_cuprite doendit "does NOT raise a conflict warning when the work package has been only commented by another user while the current- user is editing",- :aggregate_failures do+ user is editing" dousing_session(:admin) dologin_as(admin)@@ -1338,8 +1336,7 @@ RSpec.describe "Work package activity", :js, :with_cuprite doendcontext "when the current user does not have the activity tab open the whole time" do- it "raises a conflict warning when the work package is updated by another user while the current user is editing",- :aggregate_failures do+ it "raises a conflict warning when the work package is updated by another user while the current user is editing" dousing_session(:admin) dologin_as(admin)@@ -1389,8 +1386,8 @@ RSpec.describe "Work package activity", :js, :with_cuprite doendend- it "does NOT raise a conflict warning when the work package is updated by the same user while the current user is editing",- :aggregate_failures do+ it "does NOT raise a conflict warning when the work package is updated by the same user+ while the current user is editing" dousing_session(:admin) dologin_as(admin)diff --git a/spec/features/activities/work_package/emoji_reactions_spec.rb b/spec/features/activities/work_package/emoji_reactions_spec.rbindex 598a300d3e9..dc575be8ec4 100644--- a/spec/features/activities/work_package/emoji_reactions_spec.rb+++ b/spec/features/activities/work_package/emoji_reactions_spec.rb@@ -170,7 +170,7 @@ RSpec.describe "Emoji reactions on work package activity", :js, :with_cuprite doENV.delete("WORK_PACKAGES_ACTIVITIES_TAB_POLLING_INTERVAL_IN_MS")end- it "shows the updated reactions without reload", :aggregate_failures do+ it "shows the updated reactions without reload" doactivity_tab.expect_journal_notes(text: first_comment_by_member.notes)# Simulate another user adding a reactiondiff --git a/spec/features/activities/work_package_activity_spec.rb b/spec/features/activities/work_package_activity_spec.rbindex 5264004001f..48fcd28f48e 100644--- a/spec/features/activities/work_package_activity_spec.rb+++ b/spec/features/activities/work_package_activity_spec.rb@@ -69,7 +69,7 @@ RSpec.describe "Work package activity", :js doENV.delete("WORK_PACKAGES_ACTIVITIES_TAB_POLLING_INTERVAL_IN_MS")end- it "displays changed attributes in the activity tab", :aggregate_failures do+ it "displays changed attributes in the activity tab" doactivity_tab.expect_journal_changed_attribute(text: "% Complete set to 95%")activity_tab.expect_journal_changed_attribute(text: "Work set to 100h")activity_tab.expect_journal_changed_attribute(text: "Remaining work set to 5h")