Project

General

Profile

Bug #4272 » test_bug2.rb

ibc (Iñaki Baz Castillo), 01/13/2011 01:22 AM

 
require "./test_encoding"

times = ( ( ARGV[0] and ARGV[0].to_i > 0 ) ? ARGV[0].to_i : 5000 )
threads = []
num_threads = 20
tester = TestEncoding::Tester.new

times.times do |num|
puts "iteration [#{num}]"
s = tester.test_rb_enc_str_new
threads << Thread.new { } unless num_threads == 0
num_threads -= 1
end
(5-5/5)