spec/fixtures/composite_service.rb in process_handler-1.1.2 vs spec/fixtures/composite_service.rb in process_handler-2.0.0

- old
+ new

@@ -11,26 +11,34 @@ def call(params={}) puts "RESULT" end end - class Messenger + class Freddy def respond_to(*) ResponderHandler.new end end + class DummyStatsd + def histogram(*) + end + end + class ResponderHandler def shutdown end end cron_process = ProcessHandler::CronProcess.new cron_process.schedule('0.5') cron_process.schedule('5', some: 'params') - ProcessHandler::PivotProcess.logger = Logger.new('/dev/null') - pivot_process = ProcessHandler::PivotProcess.new(Messenger.new) + pivot_process = ProcessHandler::PivotProcess.new( + freddy: Freddy.new, + logger: Logger.new('/dev/null'), + statsd: DummyStatsd.new + ) ProcessHandler.start_composite do add cron_process, EchoResultService.new add pivot_process, EchoResultService.new end