def test_delete_default_tenant(appliance):
    roottenant = appliance.collections.tenants.get_root_tenant()
    view = navigate_to(appliance.collections.tenants, 'All')
    for row in view.table.rows():
        if row.name.text == roottenant.name:
            row[0].check()
    with error.handler('Default Tenant "{}" can not be deleted'.format(roottenant.name)):
        view.toolbar.configuration.item_select('Delete selected items', handle_alert=True)
Exemplo n.º 2
0
def modified_request_class(request, domain, original_request_class):
    with error.handler("error: Error during 'Automate Class copy'"):
        # methods of this class might have been copied by other fixture, so this error can occur
        original_request_class.copy_to(domain)
    klass = domain\
        .namespaces.instantiate(name='Cloud')\
        .namespaces.instantiate(name='VM')\
        .namespaces.instantiate(name='Provisioning')\
        .namespaces.instantiate(name='StateMachines')\
        .classes.instantiate(name='Methods')
    request.addfinalizer(klass.delete_if_exists)
    return klass
Exemplo n.º 3
0
def modified_request_class(request, domain, original_request_class):
    with error.handler("error: Error during 'Automate Class copy'"):
        # methods of this class might have been copied by other fixture, so this error can occur
        original_request_class.copy_to(domain)
    klass = domain\
        .namespaces.instantiate(name='Cloud')\
        .namespaces.instantiate(name='VM')\
        .namespaces.instantiate(name='Provisioning')\
        .namespaces.instantiate(name='StateMachines')\
        .classes.instantiate(name='Methods')
    request.addfinalizer(klass.delete_if_exists)
    return klass