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

Remove unused CopyOptions#dependencies validation

Alexander Brandon Colesa791c586a839
diff --git a/app/forms/projects/copy_options.rb b/app/forms/projects/copy_options.rb
index 71905e823eb..690a4e79dca 100644
--- a/app/forms/projects/copy_options.rb
+++ b/app/forms/projects/copy_options.rb
@@ -42,7 +42,5 @@ module Projects
attribute :dependencies, array: true, default: all_dependencies.keys
attribute :send_notifications, :boolean, default: false
-
- validates :dependencies, inclusion: { in: all_dependencies.keys }
end
end
diff --git a/spec/forms/projects/copy_options_spec.rb b/spec/forms/projects/copy_options_spec.rb
index f23a0d5fbcc..fd2a42e5249 100644
--- a/spec/forms/projects/copy_options_spec.rb
+++ b/spec/forms/projects/copy_options_spec.rb
@@ -37,10 +37,6 @@ RSpec.describe Projects::CopyOptions, type: :model do
it "has a default value" do
expect(subject.dependencies).to match_array(all_dependencies)
end
-
- it "validates dependencies" do
- expect(subject).to validate_inclusion_of(:dependencies).in_array(all_dependencies)
- end
end
describe "#send_notifications" do