Sha256: e75dc2ff874e2c7c13e5b9d9c5e00a3e7c5182755a4fb01227579ea9e5de3a4f

Contents?: true

Size: 212 Bytes

Versions: 34

Compression:

Stored size: 212 Bytes

Contents

# frozen_string_literal: true

class MyServerConfig < Sinclair::Config
  config_attributes :host, :port

  def url
    if @port
      "http://#{@host}:#{@port}"
    else
      "http://#{@host}"
    end
  end
end

Version data entries

34 entries across 34 versions & 1 rubygems

Version Path
sinclair-2.1.1 spec/support/models/my_server_config.rb
sinclair-2.1.0 spec/support/models/my_server_config.rb
sinclair-2.0.1 spec/support/models/my_server_config.rb
sinclair-2.0.0 spec/support/models/my_server_config.rb
sinclair-1.16.3 spec/support/models/my_server_config.rb
sinclair-1.16.2 spec/support/models/my_server_config.rb
sinclair-1.16.1 spec/support/models/my_server_config.rb
sinclair-1.16.0 spec/support/models/my_server_config.rb
sinclair-1.15.0 spec/support/models/my_server_config.rb
sinclair-1.14.2 spec/support/models/my_server_config.rb
sinclair-1.14.1 spec/support/models/my_server_config.rb
sinclair-1.14.0 spec/support/models/my_server_config.rb
sinclair-1.13.0 spec/support/models/my_server_config.rb
sinclair-1.12.1 spec/support/models/my_server_config.rb
sinclair-1.12.0 spec/support/models/my_server_config.rb
sinclair-1.11.0 spec/support/models/my_server_config.rb
sinclair-1.10.0 spec/support/models/my_server_config.rb
sinclair-1.9.0 spec/support/models/my_server_config.rb
sinclair-1.8.0 spec/support/models/my_server_config.rb
sinclair-1.7.0 spec/support/models/my_server_config.rb