(t *testing.T, conn *Conn)
| 1105 | } |
| 1106 | |
| 1107 | func testBrokers(t *testing.T, conn *Conn) { |
| 1108 | brokers, err := conn.Brokers() |
| 1109 | if err != nil { |
| 1110 | t.Error(err) |
| 1111 | } |
| 1112 | |
| 1113 | if len(brokers) != 1 { |
| 1114 | t.Errorf("expected 1 broker in %+v", brokers) |
| 1115 | } |
| 1116 | |
| 1117 | if brokers[0].ID != 1 { |
| 1118 | t.Errorf("expected ID 1 received %d", brokers[0].ID) |
| 1119 | } |
| 1120 | } |
| 1121 | |
| 1122 | func testConnBroker(t *testing.T, conn *Conn) { |
| 1123 | broker := conn.Broker() |