From 4f30e30a0846333bb61cddeb8ffc8123bf54a667 Mon Sep 17 00:00:00 2001 From: gregoirenovel Date: Thu, 27 Dec 2018 11:55:44 +0100 Subject: [PATCH] Remove the unused decorator FranceConnectInformationDecorator --- .../france_connect_information_decorator.rb | 7 ------- .../france_connect_inforation_decorator_spec.rb | 17 ----------------- 2 files changed, 24 deletions(-) delete mode 100644 app/decorators/france_connect_information_decorator.rb delete mode 100644 spec/decorators/france_connect_inforation_decorator_spec.rb diff --git a/app/decorators/france_connect_information_decorator.rb b/app/decorators/france_connect_information_decorator.rb deleted file mode 100644 index 503caee5b..000000000 --- a/app/decorators/france_connect_information_decorator.rb +++ /dev/null @@ -1,7 +0,0 @@ -class FranceConnectInformationDecorator < Draper::Decorator - delegate_all - - def gender_fr - gender == 'female' ? 'Mme' : 'M.' - end -end diff --git a/spec/decorators/france_connect_inforation_decorator_spec.rb b/spec/decorators/france_connect_inforation_decorator_spec.rb deleted file mode 100644 index d6d642fc3..000000000 --- a/spec/decorators/france_connect_inforation_decorator_spec.rb +++ /dev/null @@ -1,17 +0,0 @@ -require 'spec_helper' - -describe FranceConnectInformationDecorator do - let(:gender) { 'female' } - let(:france_connect_information) { create :france_connect_information, gender: gender } - - subject { france_connect_information.decorate.gender_fr } - - context 'when france connect user is a male' do - let(:gender) { 'male' } - it { is_expected.to eq 'M.' } - end - - context 'when france connect user is a female' do - it { is_expected.to eq 'Mme' } - end -end