MCPcopy Create free account
hub / github.com/algolia/cli / seedToken

Function seedToken

pkg/cmd/application/create/create_test.go:83–91  ·  view source on GitHub ↗

seedToken installs an in-memory keyring with a valid token.

(t *testing.T)

Source from the content-addressed store, hash-verified

81
82// seedToken installs an in-memory keyring with a valid token.
83func seedToken(t *testing.T) {
84 t.Helper()
85 keyring.MockInit()
86 require.NoError(t, auth.SaveToken(&dashboard.OAuthTokenResponse{
87 AccessToken: "test-token",
88 ExpiresIn: 3600,
89 CreatedAt: time.Now().Unix(),
90 }))
91}
92
93func samplePlanTemplates() []dashboard.PlanTemplateResource {
94 return []dashboard.PlanTemplateResource{

Callers 1

newOptsFunction · 0.70

Calls 2

SaveTokenFunction · 0.92
HelperMethod · 0.80

Tested by

no test coverage detected