MCPcopy Create free account
hub / github.com/facebook/time / TestClientConnectDialFailure

Function TestClientConnectDialFailure

ntrip/client_test.go:276–287  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

274}
275
276func TestClientConnectDialFailure(t *testing.T) {
277 c := NewClient(Config{
278 Caster: "localhost:1",
279 Mountpoint: "/M",
280 Password: "p",
281 })
282
283 ctx := context.Background()
284 err := c.Connect(ctx)
285 require.Error(t, err)
286 require.Contains(t, err.Error(), "dialing caster")
287}
288
289func TestClientConnectFullHandshake(t *testing.T) {
290 listener, err := net.Listen("tcp", "127.0.0.1:0")

Callers

nothing calls this directly

Calls 3

ConnectMethod · 0.95
NewClientFunction · 0.70
ErrorMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…