- Re-parent RestClient::Exceptions::Timeout under
RestClient::RequestTimeout. Ideally these would be separate, since
HTTP 408 is completely unrelated to network timeouts. However, making
Timeout a subclass of RequestTimeout will preserve backwards
compatibility while still making it possible to distinguish between
the cases for users who want to.
- Make all HTTP status exception classes subclasses of
RestClient::RequestFailed. Previously there were exceptions carved out
for HTTP 304, 401, and 404, which for some reason directly subclassed
the parent class of RequestFailed, ExceptionWithResponse. I don't know
what purpose this served.
The actual HTTP response code is "Not Found", and basically every other
exception matches the RFCs. Preserve ResourceNotFound as an alias for
backwards-compatibility.
Fixes: #265
* Put unit and integration specs into separate subdirectories
* Consolidate all requires of 'webmock/rspec' into spec_helper.rb
* Use WebMock.{disable!,enable!} for specs calling live server