(t *testing.T)
| 84 | } |
| 85 | |
| 86 | func TestDeclareBinding(t *testing.T) { |
| 87 | var ok bool |
| 88 | |
| 89 | b := Binding{ |
| 90 | Queue: &Queue{Name: "lol1"}, |
| 91 | Exchange: Exchange{Name: "lol2"}, |
| 92 | Key: "ololoev", |
| 93 | } |
| 94 | |
| 95 | td := &testDeclarer{ |
| 96 | _QueueBind: func() error { |
| 97 | ok = true |
| 98 | return nil |
| 99 | }, |
| 100 | } |
| 101 | |
| 102 | DeclareBinding(b)(td) |
| 103 | |
| 104 | if !ok { |
| 105 | t.Error("DeclareBinding() should call declarer.QueueBind()") |
| 106 | } |
| 107 | } |
nothing calls this directly
no test coverage detected