Sha256: f32afe2cf26d8765b2521aac076e91cd912b758cdc904f41dd1141927c03ee44

Contents?: true

Size: 347 Bytes

Versions: 17

Compression:

Stored size: 347 Bytes

Contents

RSpec.describe WorkerKiller do
  let(:logger){ Logger.new(nil) }

  describe '#randomize' do
    [1, 5, 25, 125, 5000, 10_000].each do |max|
      it "randomize(#{max})" do
        1000.times do
          rnd = WorkerKiller.randomize(max)
          expect(rnd).to be >= 0
          expect(rnd).to be < max
        end
      end
    end
  end
end

Version data entries

17 entries across 17 versions & 1 rubygems

Version Path
worker_killer-1.1.0.223443 spec/worker_killer_spec.rb
worker_killer-1.1.0.214159 spec/worker_killer_spec.rb
worker_killer-1.1.0.214146 spec/worker_killer_spec.rb
worker_killer-1.0.5.213977 spec/worker_killer_spec.rb
worker_killer-1.0.5.213889 spec/worker_killer_spec.rb
worker_killer-1.0.4.189871 spec/worker_killer_spec.rb
worker_killer-1.0.3.189564 spec/worker_killer_spec.rb
worker_killer-1.0.3.189098 spec/worker_killer_spec.rb
worker_killer-1.0.2.187852 spec/worker_killer_spec.rb
worker_killer-1.0.2.187805 spec/worker_killer_spec.rb
worker_killer-1.0.2.187732 spec/worker_killer_spec.rb
worker_killer-1.0.1.83603 spec/worker_killer_spec.rb
worker_killer-1.0.1.75538 spec/worker_killer_spec.rb
worker_killer-1.0.1.39842 spec/worker_killer_spec.rb
worker_killer-1.0.0.39841 spec/worker_killer_spec.rb
worker_killer-1.0.0.39839 spec/worker_killer_spec.rb
worker_killer-0.1.1.39838 spec/worker_killer_spec.rb