Sha256: e909cd50c754bb530e5a15145d769f30f64cffc6b720179667d7593150bbf87a

Contents?: true

Size: 514 Bytes

Versions: 1

Compression:

Stored size: 514 Bytes

Contents

class TestRunner


    def run(data=nil)
        puts 'running the runner for leroy '.upcase + ' with data: ' + data.inspect
        @times = data["times"].to_i
        @times.times do |i|
            puts 'running at ' + i.to_s
            sleep 1
        end
    end

    def set_complete(params=nil)
        puts 'SET COMPLETE YAY!' + params[:task_set_id]
    end

    def progress
        if @count
            return @count / @times
        end
        return 0.0
    end



end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
simple_worker-0.0.2 test/test_runner.rb