def test_dataReceived(self):
        """
        When data is received, it should be sent to the transport.
        """
        client = session.SSHSessionClient()
        client.transport = StubTransport()
        client.dataReceived(b'test data')
        self.assertEqual(client.transport.buf, b'test data')

        When data is received, it should be sent to the transport.
        
stackoverflow/venv/lib/python3.6/site-packages/twisted/conch/test/test_session.py