How to mock OAuth 2.0 in Go
We use OAuth 2.0 to access your information from GitHub. That way we don't have to store any sensitive data and you don't need an extra account. In production this works great. During development it makes our lives harder because GitHub needs access to our machines. We solve this problem by mocking all OAuth related networks requests to generate a fake token. This token won't give you access to the GitHub API so we also have to stub those requests.