def METHOD_NAME(params):
    """
    Check whether the output is libvirtd version.
    """
    expected_version = params.get('expected_version', 'no') == 'yes'
    is_version = log[0].startswith('{} (libvirt)'.format(daemon_name))
    if expected_version != is_version:
        test.fail(
            'Expected output version is %s, but get output:\n%s' %
            (expected_version, '\n'.join(log)))