let address champ be prefillable

This commit is contained in:
sebastiencarceles 2023-02-28 08:13:15 +01:00
parent f752dd7085
commit a7b21fcd7c
3 changed files with 4 additions and 2 deletions

View file

@ -266,6 +266,7 @@ class TypeDeChamp < ApplicationRecord
TypeDeChamp.type_champs.fetch(:regions),
TypeDeChamp.type_champs.fetch(:departements),
TypeDeChamp.type_champs.fetch(:communes),
TypeDeChamp.type_champs.fetch(:address),
TypeDeChamp.type_champs.fetch(:date),
TypeDeChamp.type_champs.fetch(:datetime),
TypeDeChamp.type_champs.fetch(:yes_no),

View file

@ -140,6 +140,7 @@ RSpec.describe PrefillParams do
it_behaves_like "a champ public value that is authorized", :drop_down_list, "value"
it_behaves_like "a champ public value that is authorized", :departements, "03"
it_behaves_like "a champ public value that is authorized", :communes, ['01', '01457']
it_behaves_like "a champ public value that is authorized", :address, "20 avenue de Ségur 75007 Paris"
it_behaves_like "a champ public value that is authorized", :annuaire_education, "0050009H"
it_behaves_like "a champ public value that is authorized", :multiple_drop_down_list, ["val1", "val2"]
it_behaves_like "a champ public value that is authorized", :dossier_link, "1"
@ -183,6 +184,7 @@ RSpec.describe PrefillParams do
it_behaves_like "a champ private value that is authorized", :siret, "13002526500013"
it_behaves_like "a champ private value that is authorized", :departements, "03"
it_behaves_like "a champ private value that is authorized", :communes, ['01', '01457']
it_behaves_like "a champ private value that is authorized", :address, "20 avenue de Ségur 75007 Paris"
it_behaves_like "a champ private value that is authorized", :annuaire_education, "0050009H"
it_behaves_like "a champ private value that is authorized", :multiple_drop_down_list, ["val1", "val2"]
it_behaves_like "a champ private value that is authorized", :dossier_link, "1"
@ -220,7 +222,6 @@ RSpec.describe PrefillParams do
it_behaves_like "a champ public value that is unauthorized", :pole_emploi, "value"
it_behaves_like "a champ public value that is unauthorized", :mesri, "value"
it_behaves_like "a champ public value that is unauthorized", :carte, "value"
it_behaves_like "a champ public value that is unauthorized", :address, "value"
it_behaves_like "a champ public value that is unauthorized", :pays, "value"
it_behaves_like "a champ public value that is unauthorized", :regions, "value"
it_behaves_like "a champ public value that is unauthorized", :departements, "value"

View file

@ -249,6 +249,7 @@ describe TypeDeChamp do
it_behaves_like "a prefillable type de champ", :type_de_champ_regions
it_behaves_like "a prefillable type de champ", :type_de_champ_departements
it_behaves_like "a prefillable type de champ", :type_de_champ_communes
it_behaves_like "a prefillable type de champ", :type_de_champ_address
it_behaves_like "a prefillable type de champ", :type_de_champ_yes_no
it_behaves_like "a prefillable type de champ", :type_de_champ_checkbox
it_behaves_like "a prefillable type de champ", :type_de_champ_drop_down_list
@ -271,7 +272,6 @@ describe TypeDeChamp do
it_behaves_like "a non-prefillable type de champ", :type_de_champ_pole_emploi
it_behaves_like "a non-prefillable type de champ", :type_de_champ_mesri
it_behaves_like "a non-prefillable type de champ", :type_de_champ_carte
it_behaves_like "a non-prefillable type de champ", :type_de_champ_address
end
describe '#normalize_libelle' do