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 Project Phase Gate traits

Dombi Attilac90aa54cea33
diff --git a/spec/factories/project_phase_factory.rb b/spec/factories/project_phase_factory.rb
index de8269b9676..f5891efb57f 100644
--- a/spec/factories/project_phase_factory.rb
+++ b/spec/factories/project_phase_factory.rb
@@ -28,11 +28,22 @@
FactoryBot.define do
factory :project_phase, class: "Project::Phase" do
+ sequence(:name) { |n| "Project Phase #{n}" }
project
definition factory: :project_phase_definition
active { true }
start_date { Date.current - 2.days }
end_date { Date.current + 2.days }
+
+ trait :with_start_gate do
+ start_gate { true }
+ sequence(:start_gate_name) { |n| "Project Start Gate #{n}" }
+ end
+
+ trait :with_end_gate do
+ end_gate { true }
+ sequence(:end_gate_name) { |n| "Project End Gate #{n}" }
+ end
end
end