MCPcopy
hub / github.com/yusing/godoxy / addHTTPRouteAt

Function addHTTPRouteAt

internal/entrypoint/inbound_mtls_test.go:449–458  ·  view source on GitHub ↗
(t *testing.T, ep *Entrypoint, alias, profile, listenAddr string, listener net.Listener)

Source from the content-addressed store, hash-verified

447}
448
449func addHTTPRouteAt(t *testing.T, ep *Entrypoint, alias, profile, listenAddr string, listener net.Listener) {
450 t.Helper()
451
452 route := newFakeHTTPRouteAt(t, alias, profile, "https://"+listenAddr)
453 if listener == nil {
454 require.NoError(t, ep.StartAddRoute(route))
455 return
456 }
457 require.NoError(t, ep.addHTTPRouteWithListener(route, listenAddr, HTTPProtoHTTPS, listener))
458}
459
460func closeTestServers(t *testing.T, ep *Entrypoint) {
461 t.Helper()

Calls 3

newFakeHTTPRouteAtFunction · 0.85
StartAddRouteMethod · 0.65

Tested by

no test coverage detected