Sha256: 0befadd5fa88955c65e74252d44520fa23034dc7101fec2cf411cadd23bbb857

Contents?: true

Size: 371 Bytes

Versions: 2

Compression:

Stored size: 371 Bytes

Contents

require 'clockwork'

module Clockwork
  LOGFILE = File.expand_path('../../tmp/signal_test.log', __FILE__)

  handler do |job|
    File.write(LOGFILE, 'start')
    sleep 0.1
    File.write(LOGFILE, 'done')
  end

  configure do |config|
    config[:sleep_timeout] = 0
    config[:logger] = Logger.new(StringIO.new)
  end

  every(1.seconds, 'run.me.every.1.seconds')
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
clockwork-2.0.2 test/samples/signal_test.rb
clockwork-2.0.1 test/samples/signal_test.rb