spec/lib/worker_spec.rb in proletariat-0.0.4 vs spec/lib/worker_spec.rb in proletariat-0.0.5
- old
+ new
@@ -29,11 +29,11 @@
end
end
describe '#work' do
it 'should raise NotImplementedError' do
- expect { Worker.new.work('message', 'key') }.to \
+ expect { Worker.new.work('message', 'key', {}) }.to \
raise_exception NotImplementedError
end
end
describe '#log' do
@@ -51,15 +51,15 @@
end
end
describe '#publish' do
it 'should forward the message to the publisher' do
- expect(Proletariat).to receive(:publish).with('topic', 'message')
- Worker.new.publish 'topic', 'message'
+ expect(Proletariat).to receive(:publish).with('topic', 'message', {})
+ Worker.new.publish 'topic', 'message', {}
end
it 'should have a blank default message' do
- expect(Proletariat).to receive(:publish).with('topic', '')
+ expect(Proletariat).to receive(:publish).with('topic', '', {})
Worker.new.publish 'topic'
end
end
describe '.listen_on' do