Sha256: d5ed00a5a90d385a15a620c3f266a6c73ea1c3ff567ea8eedcb271022b100ee9

Contents?: true

Size: 324 Bytes

Versions: 18

Compression:

Stored size: 324 Bytes

Contents

require 'singleton'

class Clients

  include Singleton

  def initialize
    @clients = {}
  end

  def [](client_name)
    @clients[client_name] ||= TestClient.new
  end

  def close
    @clients.values.each(&:close)
  end

end

def client(client_name = nil)
  client_name ||= 'client'
  Clients.instance[client_name]
end

Version data entries

18 entries across 18 versions & 2 rubygems

Version Path
ftpd-1.1.1 features/step_definitions/client.rb
ftpd-1.1.0 features/step_definitions/client.rb
investtools-ftpd-1.0.1 features/step_definitions/client.rb
ftpd-1.0.1 features/step_definitions/client.rb
ftpd-1.0.0 features/step_definitions/client.rb
ftpd-0.17.0 features/step_definitions/client.rb
ftpd-0.16.0 features/step_definitions/client.rb
ftpd-0.15.0 features/step_definitions/client.rb
ftpd-0.14.0 features/step_definitions/client.rb
ftpd-0.13.0 features/step_definitions/client.rb
ftpd-0.12.0 features/step_definitions/client.rb
ftpd-0.11.0 features/step_definitions/client.rb
ftpd-0.10.0 features/step_definitions/client.rb
ftpd-0.9.0 features/step_definitions/client.rb
ftpd-0.7.1 features/step_definitions/client.rb
ftpd-0.8.0 features/step_definitions/client.rb
ftpd-0.7.0 features/step_definitions/client.rb
ftpd-0.6.0 features/step_definitions/client.rb