MCPcopy Index your code
hub / github.com/cloudflare/cloudflared / TestUnsupportedAssociate

Function TestUnsupportedAssociate

socks/request_handler_test.go:22–30  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

20}
21
22func TestUnsupportedAssociate(t *testing.T) {
23 req := createRequest(t, socks5Version, associateCommand, "127.0.0.1", 1337, false)
24 var b bytes.Buffer
25
26 requestHandler := NewRequestHandler(NewNetDialer(), nil)
27 err := requestHandler.Handle(req, &b)
28 assert.NoError(t, err)
29 assert.True(t, b.Bytes()[1] == commandNotSupported, "expected a response")
30}
31
32func TestHandleConnect(t *testing.T) {
33 req := createRequest(t, socks5Version, connectCommand, "127.0.0.1", 1337, false)

Callers

nothing calls this directly

Calls 5

HandleMethod · 0.95
createRequestFunction · 0.85
NewRequestHandlerFunction · 0.85
NewNetDialerFunction · 0.85
BytesMethod · 0.80

Tested by

no test coverage detected