require 'spec_helper' describe Array do subject { ['My grandmom gave me a sweater for Christmas.', 'I like turtles.', 'I am a banana.'] } describe '#dogerific' do let(:options) { { ignore: [] } } let(:output) { subject.dogerific(options) } it 'delegates to Dogerific#convert for each element' do subject.each do |item| expect_any_instance_of(Dogerific).to receive(:convert).with(item, options).once end output end it 'returns an array of strings' do expect(output).to be_an_array_of String end end end