Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
var BrowserLoginFunc = func(host string, ios *iostreams.IOStreams) (string, error) { return internalauth.BrowserLogin(host, ios) }
BrowserLoginFunc is the function used to perform browser-based login. Tests may override this to avoid opening a real browser.
var ClearHostTokenFunc = func(host string) error { return config.ClearHostToken(host) }
ClearHostTokenFunc is the function used to clear the token from hosts.yml. Tests may override this to avoid touching the real config file.
var DeleteTokenFunc = func(host string) error { return internalauth.DeleteToken(host) }
DeleteTokenFunc is the function used to remove the keyring token. Tests may override this to avoid touching the real keyring.
var DeviceLoginFunc = func(host string, ios *iostreams.IOStreams) (string, error) { return internalauth.DeviceLogin(host, ios) }
DeviceLoginFunc is the function used to perform device-code login. Tests may override this to avoid real network calls.
var FetchTokenInfoFunc = func(host, token string) (internalauth.TokenInfo, error) { return internalauth.FetchTokenInfo(host, token) }
FetchTokenInfoFunc is the function used to fetch session details from the server. Tests may override this to avoid real HTTP calls.
var ResolveTokenFunc = func(host string) (internalauth.ResolvedToken, error) { return internalauth.ResolveToken(host) }
ResolveTokenFunc is the function used to resolve the auth token. Tests may override this to avoid real keyring/config access.
var SetTokenFunc = func(host, token string) error { return internalauth.SetToken(host, token) }
SetTokenFunc is the function used to store a token in the keyring. Tests may override this to avoid touching the real keyring.
Functions ¶
Types ¶
This section is empty.