Sha256: a6807d7bbcb3996c59906c36d4798527f34fa5cb2580bbf7aa5d87a377baf450

Contents?: true

Size: 548 Bytes

Versions: 7

Compression:

Stored size: 548 Bytes

Contents

require 'rubygems'
require 'test/unit'
require 'shoulda'
require 'mocha'
require 'pp'

$LOAD_PATH.unshift(File.dirname(__FILE__) + '/../lib')
require 'memcache'

system 'killall memcached 2> /dev/null'

class Test::Unit::TestCase
  def start_memcache(*ports)
    ports.each do |port|
      system("memcached -p #{port} -U 0 -d -P /tmp/memcached_#{port}.pid")
    end
    sleep 0.1
  end

  def stop_memcache(*ports)
    ports.each do |port|
      pid = File.read("/tmp/memcached_#{port}.pid").to_i
      Process.kill('TERM', pid)
    end
  end
end

Version data entries

7 entries across 7 versions & 3 rubygems

Version Path
ninjudd-memcache-0.9.1 test/test_helper.rb
memcache-1.2.0 test/test_helper.rb
segmented-memcache-1.2.1 test/test_helper.rb
segmented-memcache-1.2.0 test/test_helper.rb
memcache-1.1.0 test/test_helper.rb
memcache-1.0.1 test/test_helper.rb
memcache-1.0.0 test/test_helper.rb