def info():
    cmd = r'cscript C:\Windows\System32\slmgr.vbs /dli'
    out = __salt__['cmd.run'](cmd)

    match = re.search(r'Name: (.*)\r\nDescription: (.*)\r\nPartial Product Key: (.*)\r\nLicense Status: (.*)', out,
                      re.MULTILINE)

    if match is not None:
        groups = match.groups()
        return {
            'name': groups[0],
            'description': groups[1],
            'partial_key': groups[2],
            'licensed': 'Licensed' in groups[3]
        }

    return None
Patches `what` with `with_what`.
dataset/ETHPy150Open saltstack/salt/salt/modules/win_license.py/info--crossover with--dataset/ETHPy150Open s3rvac/retdec-python/tests/__init__.py/WithPatching.patch