jerrett-simple-flickr 0.1.0 → 0.1.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -80,7 +80,7 @@ module Flickr
80
80
 
81
81
  begin
82
82
  response = Hpricot.XML( open(url).read ).at('rsp')
83
- rescue Timeout::Error, OpenURI::HTTPError, Errno::ECONNRESET, SocketError, Errno::ECONNREFUSED => e
83
+ rescue Errno::ETIMEDOUT, Timeout::Error, OpenURI::HTTPError, Errno::ECONNRESET, SocketError, Errno::ECONNREFUSED => e
84
84
  raise RequestError.new(0, e)
85
85
  end
86
86
  raise RequestError.new(response.at('err')['code'], response.at('err')['msg']) unless response['stat'] == 'ok'
data/spec/client_spec.rb CHANGED
@@ -15,7 +15,7 @@ describe Flickr::Client do
15
15
  @flickr.request( 'favorites.getList', :user_id => '123456789N00', :per_page => 4 )
16
16
  end
17
17
 
18
- [Timeout::Error.new(nil), OpenURI::HTTPError.new(nil,nil), Errno::ECONNRESET, SocketError, Errno::ECONNREFUSED].each do |e|
18
+ [Errno::ETIMEDOUT,Timeout::Error.new(nil), OpenURI::HTTPError.new(nil,nil), Errno::ECONNRESET, SocketError, Errno::ECONNREFUSED].each do |e|
19
19
  it "should raise an appropriate error if open-uri raises #{e}" do
20
20
  @flickr.should_receive( :open ).and_raise( e )
21
21
  proc { @flickr.request( 'test.echo' ) }.should raise_error( Flickr::RequestError )
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: jerrett-simple-flickr
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jerrett Taylor