test(champ value): test compute of champ value for epci tdc
This commit is contained in:
parent
67703c94e7
commit
0aa0b27810
1 changed files with 13 additions and 0 deletions
|
@ -82,6 +82,19 @@ describe Logic::ChampValue do
|
||||||
it { is_expected.to eq('92') }
|
it { is_expected.to eq('92') }
|
||||||
end
|
end
|
||||||
|
|
||||||
|
context 'epci tdc' do
|
||||||
|
let(:champ) { build(:champ_epci, code_departement: '43') }
|
||||||
|
|
||||||
|
before do
|
||||||
|
champ.save!
|
||||||
|
champ.update_columns(external_id: '244301016', value: 'CC des Sucs')
|
||||||
|
end
|
||||||
|
|
||||||
|
it do
|
||||||
|
is_expected.to eq('43')
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
context 'region tdc' do
|
context 'region tdc' do
|
||||||
let(:champ) { create(:champ_regions, value: 'La Réunion') }
|
let(:champ) { create(:champ_regions, value: 'La Réunion') }
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue