Merge pull request #7873 from betagouv/remove-zones-validation
a procedure without zone is finally valid
This commit is contained in:
commit
1c37fd7a6f
2 changed files with 0 additions and 14 deletions
|
@ -289,7 +289,6 @@ class Procedure < ApplicationRecord
|
|||
|
||||
validates :lien_dpo, email_or_link: true, allow_nil: true
|
||||
validates_with MonAvisEmbedValidator
|
||||
validates :zones, presence: true, if: -> record { record.publiee? && Flipper.enabled?(:zonage) }
|
||||
|
||||
FILE_MAX_SIZE = 20.megabytes
|
||||
validates :notice, content_type: [
|
||||
|
|
|
@ -334,19 +334,6 @@ describe Administrateurs::ProceduresController, type: :controller do
|
|||
|
||||
it { expect(subject.for_individual).not_to eq procedure_params[:for_individual] }
|
||||
end
|
||||
|
||||
context 'when zones are empty' do
|
||||
before do
|
||||
Flipper.enable(:zonage)
|
||||
end
|
||||
|
||||
after do
|
||||
Flipper.disable(:zonage)
|
||||
end
|
||||
|
||||
let(:zone_ids) { [""] }
|
||||
it { is_expected.to render_template :zones }
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue