Sha256: 15f7bfb0c1b7bdcaba152220151a1b92ee7abe6d4b3ec0e5cff67b55cb1d8ebe
Contents?: true
Size: 940 Bytes
Versions: 2
Compression:
Stored size: 940 Bytes
Contents
require "spec/helper/all" require "remcached" describe Memcached do it "should yield until connection is ready" do EventMachine.synchrony do Memcached.connect %w(localhost) Memcached.usable?.should eq(true) EventMachine.stop end end it "should fire sequential memcached requests" do EventMachine.synchrony do Memcached.connect %w(localhost) Memcached.get(key: 'hai') do |res| res[:value].should match('Not found') end Memcached.set(key: 'hai', value: 'win') Memcached.add(key: 'count') Memcached.delete(key: 'hai') EventMachine.stop end end it "should fire multi memcached requests" do skip "patch mult-get" EventMachine.synchrony do Memcached.connect %w(localhost) Memcached.multi_get([{:key => 'foo'},{:key => 'bar'}, {:key => 'test'}]) do |res| # TODO EventMachine.stop end end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
em-synchrony-1.0.6 | spec/remcached_spec.rb |
em-synchrony-1.0.5 | spec/remcached_spec.rb |