Skip to content

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

trying to avoid flaky spec

Jonas Jabari352e4b73b38c
diff --git a/spec/features/activities/work_package/activities_spec.rb b/spec/features/activities/work_package/activities_spec.rb
index 1e822b5be9d..4fc189a4b6d 100644
--- a/spec/features/activities/work_package/activities_spec.rb
+++ b/spec/features/activities/work_package/activities_spec.rb
@@ -525,6 +525,7 @@ RSpec.describe "Work package activity", :js, :with_cuprite, with_flag: { primeri
it "resets an only_changes filter if a comment is added by the user", :aggregate_failures do
activity_tab.filter_journals(:only_changes)
+ sleep 0.5 # avoid flaky test
# expect only the changes
activity_tab.expect_no_journal_notes(text: "First comment by admin")
@@ -532,6 +533,7 @@ RSpec.describe "Work package activity", :js, :with_cuprite, with_flag: { primeri
# add a comment
activity_tab.add_comment(text: "Third comment by admin")
+ sleep 0.5 # avoid flaky test
# the only_changes filter should be reset
activity_tab.expect_journal_notes(text: "Third comment by admin")