MCPcopy
hub / github.com/cloudfoundry/cli / NewTestRouterClient

Function NewTestRouterClient

api/router/router_suite_test.go:46–57  ·  view source on GitHub ↗
(config router.Config)

Source from the content-addressed store, hash-verified

44}
45
46func NewTestRouterClient(config router.Config) *router.Client {
47 resource, err := url.Parse("/routing")
48 Expect(err).ToNot(HaveOccurred())
49 baseURL, err := url.Parse(server.URL())
50 Expect(err).ToNot(HaveOccurred())
51
52 config.RoutingEndpoint = baseURL.ResolveReference(resource).String()
53 config.SkipSSLValidation = true
54 client := router.NewClient(config)
55
56 return client
57}

Callers 1

Calls 4

NewClientFunction · 0.92
ParseMethod · 0.65
StringMethod · 0.65
URLMethod · 0.45

Tested by

no test coverage detected