Class: Saucer::Config::Common
- Inherits:
-
Object
- Object
- Saucer::Config::Common
- Defined in:
- lib/saucer/config/common.rb
Direct Known Subclasses
Constant Summary collapse
- CONFIG_PARAMS =
%i(auto_accept_alerts name build tags custom_data max_duration command_timeout idle_timeout prerun executable args background timeout tunnel_identifier parent_tunnel screen_resolution timezone avoid_proxy public record_video video_upload_on_pass record_screenshots record_logs capture_html priority webdriver_remote_quiet_exceptions).freeze
Instance Attribute Summary collapse
-
#access_key ⇒ Object
readonly
Returns the value of attribute access_key.
-
#config_params ⇒ Object
readonly
Returns the value of attribute config_params.
-
#url ⇒ Object
readonly
Returns the value of attribute url.
-
#username ⇒ Object
readonly
Returns the value of attribute username.
Instance Method Summary collapse
-
#initialize(opts = {}) ⇒ Common
constructor
A new instance of Common.
Constructor Details
#initialize(opts = {}) ⇒ Common
Returns a new instance of Common.
13 14 15 16 17 18 19 20 |
# File 'lib/saucer/config/common.rb', line 13 def initialize(opts = {}) @username = opts.delete(:username) || ENV['SAUCE_USERNAME'] @access_key = opts.delete(:access_key) || ENV['SAUCE_ACCESS_KEY'] @url = opts.delete(:url) || "https://#{@username}:#{@access_key}@ondemand.saucelabs.com:443/wd/hub" @opts = opts @config_params = CONFIG_PARAMS end |
Instance Attribute Details
#access_key ⇒ Object (readonly)
Returns the value of attribute access_key.
11 12 13 |
# File 'lib/saucer/config/common.rb', line 11 def access_key @access_key end |
#config_params ⇒ Object (readonly)
Returns the value of attribute config_params.
11 12 13 |
# File 'lib/saucer/config/common.rb', line 11 def config_params @config_params end |
#url ⇒ Object (readonly)
Returns the value of attribute url.
11 12 13 |
# File 'lib/saucer/config/common.rb', line 11 def url @url end |
#username ⇒ Object (readonly)
Returns the value of attribute username.
11 12 13 |
# File 'lib/saucer/config/common.rb', line 11 def username @username end |