Add ParseBasicAuthHeader function

ParseBasicAuthHeader parses basic auth credentials from http headers.

(Review request: http://reviews.vapour.ws/r/662/)
I think the condition here should check for test.expectError.
Something like:
if test.expectError != nil { c.Assert(err, gc.ErrorMatches, test.expectError}
else { assert error is nil}

Otherwise this would still pass if an error is expected but not obtained.