test/setup.rb in memcached-0.9 vs test/setup.rb in memcached-0.10
- old
+ new
@@ -1,16 +1,17 @@
# Start memcached
HERE = File.dirname(__FILE__)
-`ps awx`.split("\n").grep(/4304[2-3]/).map do |process|
+`ps awx`.split("\n").grep(/4304[2-6]/).map do |process|
system("kill -9 #{process.to_i}")
end
log = "/tmp/memcached.log"
system ">#{log}"
verbosity = (ENV['DEBUG'] ? "-vv" : "")
-system "memcached #{verbosity} -p 43042 >> #{log} 2>&1 &"
-system "memcached #{verbosity} -p 43043 >> #{log} 2>&1 &"
+(43042..43046).each do |port|
+ system "memcached #{verbosity} -p #{port} >> #{log} 2>&1 &"
+end
\ No newline at end of file