HeyWatch/heywatch-ruby — pull request #4 by michelegera (2014-10-17 10:22:30+00:00)
Title: Allow initializing a client with extra options

While I was dealing with a SSL issue caused by the POODLE vulnerability, I realized that I could fix my problem by passing an extra `ssl_version` option to `RestClient` when initializing the connection.

This patch allows that. If you feel it’s too liberal, I can scope it down to fetch only one or more options –

```ruby
def initialize(user=nil, password=nil, options={})
ssl_version = options.fetch(:ssl_version) {}
# …
@cli = RestClient::Resource.new(URL, {:user => user, :password => password, :headers =>
{:user_agent => "HeyWatch Ruby/#{VERSION}", :accept => "application/json"},
:ssl_version => ssl_version})
# …
```

Incidentally, I fixed a test that was failing for me: the accepted maximum `video_bitrate` seem to be way more than what the documentation states.