MCPcopy Create free account
hub / github.com/assembla/cony / TestClient_Consume

Function TestClient_Consume

client_test.go:35–49  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

33}
34
35func TestClient_Consume(t *testing.T) {
36 c := NewClient()
37 cons := &Consumer{}
38 c.Consume(cons)
39
40 if _, ok := c.consumers[cons]; !ok {
41 t.Error("should save consumer")
42 }
43
44 c.deleteConsumer(cons)
45
46 if _, ok := c.consumers[cons]; ok {
47 t.Error("should remove consumer")
48 }
49}
50
51func TestClient_Publish(t *testing.T) {
52 c := NewClient()

Callers

nothing calls this directly

Calls 3

ConsumeMethod · 0.95
deleteConsumerMethod · 0.95
NewClientFunction · 0.85

Tested by

no test coverage detected