forked from remote/oauth2
oauth2: removing unnecessary interface definitions.
This commit is contained in:
@@ -15,7 +15,7 @@ func (t *mockTransport) RoundTrip(req *http.Request) (resp *http.Response, err e
|
||||
return t.rt(req)
|
||||
}
|
||||
|
||||
func newTestConf() Config {
|
||||
func newTestConf() *Config {
|
||||
conf, _ := NewConfig(&Options{
|
||||
ClientID: "CLIENT_ID",
|
||||
ClientSecret: "CLIENT_SECRET",
|
||||
@@ -77,7 +77,7 @@ func TestExchangingTransport(t *testing.T) {
|
||||
func TestFetchWithNoRedirect(t *testing.T) {
|
||||
DefaultTransport = http.DefaultTransport
|
||||
|
||||
fetcher := newTestConf().(TokenFetcher)
|
||||
fetcher := newTestConf()
|
||||
_, err := fetcher.FetchToken(&Token{})
|
||||
if err == nil {
|
||||
t.Fatalf("Fetch should return an error if no refresh token is set")
|
||||
|
||||
Reference in New Issue
Block a user