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

Timing issue solved with retry_block

Aleix Suau2b07cb2d23eb
diff --git a/modules/bim/spec/features/viewer/show_viewpoint_spec.rb b/modules/bim/spec/features/viewer/show_viewpoint_spec.rb
index b553b742e6b..73f79828603 100644
--- a/modules/bim/spec/features/viewer/show_viewpoint_spec.rb
+++ b/modules/bim/spec/features/viewer/show_viewpoint_spec.rb
@@ -62,10 +62,10 @@ describe 'Show viewpoint in model viewer',
model_tree.expand_tree
model_tree.expect_checked 'minimal'
model_tree.all_checkboxes.each do |label, checkbox|
- if label.text == 'minimal' || label.text == 'LUB_Segment_new:S_WHG_Ess:7243035'
- expect(checkbox).to be_checked
- else
- expect(checkbox).to_not be_checked
+ retry_block do
+ if (label.text == 'minimal' || label.text == 'LUB_Segment_new:S_WHG_Ess:7243035') != checkbox.checked?
+ raise 'Checkbox checked status is wrong'
+ end
end
end
end