spec/unit/yaks/runner_spec.rb in yaks-0.6.2 vs spec/unit/yaks/runner_spec.rb in yaks-0.7.0

- old
+ new

@@ -11,12 +11,12 @@ describe '#call' do let(:runner) { Class.new(described_class) do def steps - [ [:step1, ->(x) { x + 35 }], - [:step2, ->(x) { "#{x} #{x}"}] ] + [ [:step1, proc { |x| x + 35 }], + [:step2, proc { |x| "#{x} #{x}" }] ] end end.new(object: object, config: config, options: options) } let(:object) { 7 } @@ -217,15 +217,15 @@ end end } it 'should try to find an explicitly configured serializer' do - expect(runner.serializer.call('42')).to eql 'serialized 42' + expect(runner.serializer.call('42', {})).to eql 'serialized 42' end end it 'should fall back to the policy' do - expect(runner.serializer.call([1,2,3])).to eql "[\n 1,\n 2,\n 3\n]" + expect(runner.serializer.call([1,2,3], {})).to eql "[\n 1,\n 2,\n 3\n]" end end describe '#steps' do let(:options) {{ mapper: Yaks::Mapper }}