Sha256: b36ee26e08f215da61df63b332178ec7b6233e441ee15bfd7cc81403c568a1eb
Contents?: true
Size: 861 Bytes
Versions: 19
Compression:
Stored size: 861 Bytes
Contents
require 'spec_helper' describe Epics::Error::BusinessError do subject { Epics::Error::BusinessError.new(code) } before do stub_const("Epics::Error::BusinessError::ERRORS", { "123" => { "symbol" => "BOTTMUEHLE", "short_text" => "home of awesome", } }) end let(:code) { '123' } describe '#to_s' do it 'returns a message composed of symbol and short text' do expect(subject.to_s).to eql('BOTTMUEHLE - home of awesome') end end describe '#code' do it 'returns the code' do expect(subject.code).to eql('123') end end describe '#symbol' do it 'returns the symbol' do expect(subject.symbol).to eql('BOTTMUEHLE') end end describe '#short_text' do it 'returns the short text' do expect(subject.short_text).to eql('home of awesome') end end end
Version data entries
19 entries across 19 versions & 1 rubygems