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

Add test about done_ratio focused field

Christophe Bliard477c206c4742
diff --git a/spec/components/work_packages/progress/work_based/modal_body_component_spec.rb b/spec/components/work_packages/progress/work_based/modal_body_component_spec.rb
index a304347e2c2..c6f59614379 100644
--- a/spec/components/work_packages/progress/work_based/modal_body_component_spec.rb
+++ b/spec/components/work_packages/progress/work_based/modal_body_component_spec.rb
@@ -66,5 +66,13 @@ RSpec.describe WorkPackages::Progress::WorkBased::ModalBodyComponent,
expect(component.focused_field).to eq(:remaining_hours)
end
end
+
+ context "when given percentageDone" do
+ let(:focused_field) { "percentageDone" }
+
+ it "returns :done_ratio" do
+ expect(component.focused_field).to eq(:done_ratio)
+ end
+ end
end
end