In the case of the headers message, there is a message size limit related to the number of headers that kicks in about one order of magnitude below the message sizes being tested here. When inspecting the log, you can see that the following lines are being logged, showing that the node actually rejects these message sizes:
```
Misbehaving: peer=0 (0 -> 20): too-many-headers: headers message size = 2097146
Misbehaving: peer=0 (0 -> 20): too-many-headers: headers message size = 1999996
Misbehaving: peer=0 (0 -> 20): too-many-headers: headers message size = 999996
```
In a future diff the misbehavior score increment will be bumped from 20 to 100, and the peer will actually be disconnected, which would cause the removed tests to fail on `conn.send_and_ping`.
See D16343 for why these tests where added.
Depends on D18025