Permalink
Browse files

add logging of response.body for unprocessible entity

  • Loading branch information...
1 parent ee303c6 commit 18ba657fe054206a55c0cfaa794d6f4f2f533911 Chad Pytel committed Apr 16, 2012
Showing with 5 additions and 4 deletions.
  1. +2 −2 Gemfile.lock
  2. +1 −1 lib/fetchapp-api-ruby/base.rb
  3. +2 −1 test/test_helper.rb
View
4 Gemfile.lock
@@ -1,7 +1,7 @@
PATH
remote: .
specs:
- fetchapp-api-ruby (1.2.4)
+ fetchapp-api-ruby (1.2.5)
httparty
GEM
@@ -14,7 +14,7 @@ GEM
metaclass (0.0.1)
mocha (0.10.5)
metaclass (~> 0.0.1)
- multi_json (1.2.0)
+ multi_json (1.3.0)
multi_xml (0.4.2)
PLATFORMS
View
2 lib/fetchapp-api-ruby/base.rb
@@ -84,7 +84,7 @@ def self.handle_response(response) #:nodoc:
when 300.399 then
raise(response.messsage)
when 400..499 then
- raise(response.message)
+ raise(response.message + ":" + response.body)
when 500..599 then
raise(response.message)
else
View
3 test/test_helper.rb
@@ -2,7 +2,8 @@
require 'test/unit'
require 'fakeweb'
require 'mocha'
-require 'lib/fetchapp-api-ruby'
+require 'fetchapp-api-ruby'
+require 'pry'
FakeWeb.allow_net_connect = false

0 comments on commit 18ba657

Please sign in to comment.