Reimplement HUB_TEST_HOST support using a custom http.Transport

In testing, we want to redirect all requests to a local test server
pretending to be GitHub API, but we want them to preserve their original
"Host" header. A good place to do that transparently is the `RoundTrip`
method that handles every request for this http.Client instance.
Expect encoding declaration in "Accept" HTTP header
Have `am/apply` use API for getting patches instead of curl

This enables fetching patches from private repos that you have access to.