]> git.saurik.com Git - redis.git/blob - client-libraries/ruby/spec/server_spec.rb
Redis 0.100 released
[redis.git] / client-libraries / ruby / spec / server_spec.rb
1 require File.dirname(__FILE__) + '/spec_helper'
2
3 describe "Server" do
4 before(:each) do
5 @server = Server.new 'localhost', '6379'
6 end
7
8 it "should checkout active connections" do
9 threads = []
10 10.times do
11 threads << Thread.new do
12 lambda {
13 socket = @server.socket
14 socket.close
15 socket.write("INFO\r\n")
16 socket.read(1)
17 }.should_not raise_error(Exception)
18 end
19 end
20 end
21
22 end