def METHOD_NAME(test, params, env):
    """
    Run qemu_iotests.sh script:
    1) Do some qemu_io operations(write & read etc.)
    2) Check whether qcow image file is corrupted
    :param test:   QEMU test object
    :param params: Dictionary with the test parameters
    :param env:    Dictionary with test environment.
    """
    test_type = params.get("test_type")
    qemu_io_config = None
    if test_type == "lvm":
        qemu_io_config = QemuIOConfig(test, params)
        qemu_io_config.setup()
    test_script = os.path.join(data_dir.get_shared_dir(),
                               'scripts/qemu_iotests.sh')
    test_image = params.get("test_image",
                            os.path.join(test.tmpdir, "test.qcow2"))
    test.log.info("Run script(%s) with image(%s)",
                  test_script, test_image)
    s, test_result = aexpect.run_fg("sh %s %s" % (test_script,
                                                  test_image),
                                    test.log.debug, timeout=1800)
    err_string = {
        "err_nums": r"\d errors were found on the image.",
        "an_err": "An error occurred during the check",
        "unsupt_err": "This image format does not support checks",
        "mem_err": "Not enough memory",
        "open_err": "Could not open",
        "fmt_err": "Unknown file format",
        "commit_err": "Error while committing image",
        "bootable_err": "no bootable device",
    }
    try:
        for err_type in err_string.keys():
            msg = re.findall(err_string.get(err_type), test_result)
            if msg:
                test.fail(msg)
    finally:
        try:
            if qemu_io_config:
                qemu_io_config.cleanup()
        except Exception as e:
            test.log.warn(e)