def add_vol_template(sto, name, sto_sys, sto_pool, size,
                     shareable, description, provisionType, first_avaliable):
    systems = sto.get_storage_systems()
    for sys in systems:
        if sys['name'] == sto_sys or first_avaliable:
            # search managed pools in matching storage system
            pools = sys['managedPools']
            for pool in pools:
                if pool['name'] == sto_pool:
                    storagePoolUri = pool['uri']
                    print('Adding Volume Template')
                    ret = sto.add_storage_volume_template(name,
                                                          int(size)*1024*1024*1024,
                                                          shareable,
                                                          storagePoolUri,
                                                          description,
                                                          provisionType)
                    if ret in 'provisioning':
                        print('Name:          ', ret['name'])
                        print('State:         ', ret['state'])
                        print('Capacity:      ', ret['provisioning']['capacity'])
                        print('Type:          ', ret['provisioning']['provisionType'])
                        print('Shareable:     ', ret['provisioning']['shareable'])
                    else:
                        pprint(ret)
                    return
            print('Pool: ', sto_pool, ' not found')
            return
    print('Storage System: ', stosys_name, ' not found')
dataset/ETHPy150Open HewlettPackard/python-hpOneView/examples/scripts/add-volume-template.py/add_vol_template/swapped operands of `in`