require File.join(Dir.pwd, 'spec', 'spec_helper') describe 'Experian::DataDictionary 0139' do context 'valid lookup' do it { expect( Experian::DataDictionary.lookup('0139','1') ).to eq('1 Response') } it { expect( Experian::DataDictionary.lookup('0139','2') ).to eq('2 Responses') } it { expect( Experian::DataDictionary.lookup('0139','3') ).to eq('3 Responses') } it { expect( Experian::DataDictionary.lookup('0139','4') ).to eq('4 Responses') } it { expect( Experian::DataDictionary.lookup('0139','5') ).to eq('5 Responses') } it { expect( Experian::DataDictionary.lookup('0139','6') ).to eq('6 Responses') } it { expect( Experian::DataDictionary.lookup('0139','7') ).to eq('7 Responses') } it { expect( Experian::DataDictionary.lookup('0139','8') ).to eq('8 Responses') } it { expect( Experian::DataDictionary.lookup('0139','9') ).to eq('9 Responses') } it { expect( Experian::DataDictionary.lookup('0139','0') ).to eq('0 Responses') } it { expect( Experian::DataDictionary.lookup('0139',' ') ).to eq('Unknown') } end context 'invalid lookup' do it { expect( Experian::DataDictionary.lookup('0139','10') ).to eq('Unknown') } it { expect( Experian::DataDictionary.lookup('0139','21') ).to eq('Unknown') } it { expect( Experian::DataDictionary.lookup('0139','423') ).to eq('Unknown') } end end