* func fromStateTuples(tuples []gomatrixserverlib.StateKeyTuple, omitTuples []gomatrixserverlib.StateKeyTuple) (result []*gomatrixserverlib.HeaderedEvent) { NextTuple: for _, t := range tuples { for _, o := range omitTuples { if t == o { break NextTuple } } h, ok := testSta
(t *testing.T, got []api.InputRoomEvent, want []*gomatrixserverlib.HeaderedEvent)
| 240 | */ |
| 241 | |
| 242 | func assertInputRoomEvents(t *testing.T, got []api.InputRoomEvent, want []*gomatrixserverlib.HeaderedEvent) { |
| 243 | for _, g := range got { |
| 244 | fmt.Println("GOT ", g.Event.EventID()) |
| 245 | } |
| 246 | if len(got) != len(want) { |
| 247 | t.Errorf("wrong number of InputRoomEvents: got %d want %d", len(got), len(want)) |
| 248 | return |
| 249 | } |
| 250 | for i := range got { |
| 251 | if got[i].Event.EventID() != want[i].EventID() { |
| 252 | t.Errorf("InputRoomEvents[%d] got %s want %s", i, got[i].Event.EventID(), want[i].EventID()) |
| 253 | } |
| 254 | } |
| 255 | } |
| 256 | |
| 257 | // The purpose of this test is to check that receiving an event over federation for which we have the prev_events works correctly, and passes it on |
| 258 | // to the roomserver. It's the most basic test possible. |
no outgoing calls
no test coverage detected