def test_tooLongSend(self):
        """
        Send too much data: that should cause an error.
        """
        r = self.getProtocol()
        tooSend = b"b" * (2**(r.prefixLength * 8) + 1)
        self.assertRaises(AssertionError, r.sendString, tooSend)

        Send too much data: that should cause an error.
        
stackoverflow/venv/lib/python3.6/site-packages/twisted/protocols/test/test_basic.py