def METHOD_NAME(server):
    ''' Check message handler can correctly handle events from the server.
    And the thread is correctly handled that we can do something in the message_handler '''
    # echo_server = MessageServer((localhost, echo_port))
    # echo_server.start()
    client = unrealcv.Client((localhost, echo_port))
    def handle_message(msg):
        print('Got server message %s' % repr(msg))
        res = unrealcv.client.request('ok', 1)
        assert res == 'ok'
        print('Server response %s' % res)
    client.connect()
    assert client.isconnected() == True
    client.message_handler = handle_message
    res = client.request('ok')
    assert res == 'ok'
    server.send('Hello from server')
    # echo_server.shutdown()