uber/clay — pull request #19 by Roguelazer (2013-08-29 20:13:10+00:00)
Title: Fix a bug with error handling in clay.http and add unit tests for it

`clay.http` assumed that any HTTPError could be successfully read; this isn't the case if there was a DNS resolution error or a socket connection error (according to the urllib2 code and my own testing).

I also changed the urlopen call to explicitly close the response; I know it happens whenever garbage collection happens, but it seems safest to ensure that our sockets get closed as soon as possible.

Finally, adds unit tests for `clay.http` with 100% coverage according to nose-cov.