Docserver: Fix GitHub authentication issues that have recently cropped up: use
base64.b64encode not base64.encode because the latter inserts a \n, and add a
User-Agent header.

R=yoz@chromium.org

Review URL: https://codereview.chromium.org/98183003

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@238209 0039d316-1c4b-4281-b951-d872f2087c98
SVN changes up to revision 238209
Remove some duplicate code in quic tests.
BUG=None

Review URL: https://codereview.chromium.org/54043003

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@238210 0039d316-1c4b-4281-b951-d872f2087c98
SVN changes up to revision 238210