MCPcopy Index your code
hub / github.com/rilldata/rill / NewClient

Method NewClient

admin/testadmin/testadmin.go:263–268  ·  view source on GitHub ↗

NewClient creates a new client for the fixture's server.

(t *testing.T, token string)

Source from the content-addressed store, hash-verified

261
262// NewClient creates a new client for the fixture's server.
263func (f *Fixture) NewClient(t *testing.T, token string) *client.Client {
264 c, err := client.New(f.ExternalURL(), token, "test")
265 require.NoError(t, err)
266 t.Cleanup(func() { require.NoError(t, c.Close()) })
267 return c
268}
269
270// ExternalURL returns the localhost URL of the fixture's server.
271func (f *Fixture) ExternalURL() string {

Calls 4

ExternalURLMethod · 0.95
NewFunction · 0.92
CleanupMethod · 0.65
CloseMethod · 0.65

Tested by 5

TestMCPFunction · 0.64
TestRBACFunction · 0.64
TestProjectVariablesFunction · 0.64
TestUserFunction · 0.64