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

Fix timing issues

Aaron Contrerased497d58a504
diff --git a/spec/features/projects/export_spec.rb b/spec/features/projects/export_spec.rb
index be4cff6c892..326f8917ebb 100644
--- a/spec/features/projects/export_spec.rb
+++ b/spec/features/projects/export_spec.rb
@@ -97,8 +97,7 @@ RSpec.describe "project export", :js, :with_cuprite do
"Name or identifier",
"contains",
["Important"])
-
- index_page.apply_filters
+ wait_for_reload
index_page.set_columns("Name", "Description")
diff --git a/spec/features/projects/persisted_lists_spec.rb b/spec/features/projects/persisted_lists_spec.rb
index 726fbd501d8..73705e0b05b 100644
--- a/spec/features/projects/persisted_lists_spec.rb
+++ b/spec/features/projects/persisted_lists_spec.rb
@@ -307,10 +307,8 @@ RSpec.describe "Persisted lists on projects index page",
projects_page.filter_by_membership("yes")
- wait_for_reload # chnaging filters is still done via page reload
-
- projects_page.expect_projects_listed(project, development_project)
projects_page.expect_projects_not_listed(public_project)
+ projects_page.expect_projects_listed(project, development_project)
projects_page.set_columns("Name")
projects_page.expect_columns("Name")
diff --git a/spec/features/projects/projects_index_spec.rb b/spec/features/projects/projects_index_spec.rb
index 1e2c39adc1b..d21677e0055 100644
--- a/spec/features/projects/projects_index_spec.rb
+++ b/spec/features/projects/projects_index_spec.rb
@@ -761,8 +761,8 @@ RSpec.describe "Projects index page", :js, :with_cuprite, with_settings: { login
"today")
wait_for_reload
- expect(page).to have_text(project_created_on_today.name)
expect(page).to have_no_text(project_created_on_this_week.name)
+ expect(page).to have_text(project_created_on_today.name)
expect(page).to have_no_text(project_created_on_fixed_date.name)
# created on 'this week' shows projects that were created within the last seven days
@@ -773,9 +773,9 @@ RSpec.describe "Projects index page", :js, :with_cuprite, with_settings: { login
"this week")
wait_for_reload
+ expect(page).to have_no_text(project_created_on_fixed_date.name)
expect(page).to have_text(project_created_on_today.name)
expect(page).to have_text(project_created_on_this_week.name)
- expect(page).to have_no_text(project_created_on_fixed_date.name)
# created on 'on' shows projects that were created within the last seven days
projects_page.remove_filter("created_at")
@@ -898,12 +898,12 @@ RSpec.describe "Projects index page", :js, :with_cuprite, with_settings: { login
["2011-11-11"])
wait_for_reload
- expect(page).to have_text(project_created_on_today.name)
expect(page).to have_no_text(project_created_on_fixed_date.name)
+ expect(page).to have_text(project_created_on_today.name)
# Disabling a CF in the project should remove the project from results
- project_created_on_today.project_custom_field_project_mappings.destroy_al
+ project_created_on_today.project_custom_field_project_mappings.destroy_all
wait_for_reload
expect(page).to have_no_text(project_created_on_today.name, wait: 1)