The purpose of this test is to check that if the event received fails auth checks the event is still sent to the roomserver as it does the auth check.
(t *testing.T)
| 269 | // The purpose of this test is to check that if the event received fails auth checks the event is still sent to the roomserver |
| 270 | // as it does the auth check. |
| 271 | func TestTransactionFailAuthChecks(t *testing.T) { |
| 272 | rsAPI := &testRoomserverAPI{} |
| 273 | pdus := []json.RawMessage{ |
| 274 | testData[len(testData)-1], // a message event |
| 275 | } |
| 276 | txn := mustCreateTransaction(rsAPI, &txnFedClient{}, pdus) |
| 277 | mustProcessTransaction(t, txn, []string{}) |
| 278 | // expect message to be sent to the roomserver |
| 279 | assertInputRoomEvents(t, rsAPI.inputRoomEvents, []*gomatrixserverlib.HeaderedEvent{testEvents[len(testEvents)-1]}) |
| 280 | } |
| 281 | |
| 282 | // The purpose of this test is to make sure that when an event is received for which we do not know the prev_events, |
| 283 | // we request them from /get_missing_events. It works by setting PrevEventsExist=false in the roomserver query response, |
nothing calls this directly
no test coverage detected