airgun.views.rhai

Module Contents

Classes

InsightsOrganizationErrorView

View displayed when no Organization is selected or when the current organization has no

AllRulesView

Base view for Satellite pages

InventoryAllHosts

Base view for Satellite pages

InventoryHostRule

Insights inventory host rule widget

InventoryHostDetails

Base view for Satellite pages

OverviewDetailsView

Base view for Satellite pages

ActionsDetailsView

Base view for Satellite pages

ManageDetailsView

Base view for Satellite pages

AllPlansView

Base view for Satellite pages

PlanEditView

View is a kind of abstract widget that can hold another widgets. Remembers the order,

AddPlanView

Base view for Satellite pages

PlanModalWindow

View is a kind of abstract widget that can hold another widgets. Remembers the order,

class airgun.views.rhai.InsightsOrganizationErrorView(parent, logger=None, **kwargs)

View displayed when no Organization is selected or when the current organization has no manifest

title
message
property is_displayed

Overrides the Widget.is_displayed(). The difference is that if the view does not have the root locator, it assumes it is displayed.

Returns

bool

read(widget_names=None)

Reads the contents of the view and presents them as a dictionary.

Parameters

widget_names – If specified, will read only the widgets names in the list.

Returns

A dict of widget_name: widget_read_value where the values are retrieved using the Widget.read().

class airgun.views.rhai.AllRulesView(parent, logger=None, **kwargs)

Base view for Satellite pages

title
search
property is_displayed

Overrides the Widget.is_displayed(). The difference is that if the view does not have the root locator, it assumes it is displayed.

Returns

bool

class airgun.views.rhai.InventoryAllHosts(parent, logger=None, **kwargs)

Base view for Satellite pages

title
search
actions
systems_count
table
property is_displayed

Overrides the Widget.is_displayed(). The difference is that if the view does not have the root locator, it assumes it is displayed.

Returns

bool

class airgun.views.rhai.InventoryHostRule(parent, locator, logger=None)

Insights inventory host rule widget

remove_button
title
class airgun.views.rhai.InventoryHostDetails(parent, logger=None, **kwargs)

Base view for Satellite pages

class rules(parent, logger=None, **kwargs)

A host for widgets list. Items that can be added or removed, mainly used in profile for network interfaces, storage and job template.

Usage:

@View.nested
class resources(RemovableWidgetsItemsListView):
    ROOT = "//fieldset[@id='storage_volumes']"
    ITEMS = "./div/div[contains(@class, 'removable-item')]"
    ITEM_WIDGET_CLASS = ComputeResourceRHVProfileStorageItem
ROOT = .//div[@class='rule-summaries']
ITEMS = .//div[contains(@class, 'rule-summary')]
ITEM_WIDGET_CLASS
hostname
close
property is_displayed

Overrides the Widget.is_displayed(). The difference is that if the view does not have the root locator, it assumes it is displayed.

Returns

bool

class airgun.views.rhai.OverviewDetailsView(parent, logger=None, **kwargs)

Base view for Satellite pages

title
inventory
security_issues
stability_issues
property is_displayed

Overrides the Widget.is_displayed(). The difference is that if the view does not have the root locator, it assumes it is displayed.

Returns

bool

class airgun.views.rhai.ActionsDetailsView(parent, logger=None, **kwargs)

Base view for Satellite pages

title
export_csv
stability_issues
security_issues
class airgun.views.rhai.ManageDetailsView(parent, logger=None, **kwargs)

Base view for Satellite pages

title
enable_service
status
account_number
check_connection
save
class airgun.views.rhai.AllPlansView(parent, logger=None, **kwargs)

Base view for Satellite pages

class plan(parent, logger=None, **kwargs)

Parametrized view for a nested plan view. Takes plan name on instantiation

PARAMETERS = ['plan_name']
ROOT
title
delete
edit
ansible_actions
export_csv
add_actions
title
create_plan
property is_displayed

Overrides the Widget.is_displayed(). The difference is that if the view does not have the root locator, it assumes it is displayed.

Returns

bool

class airgun.views.rhai.PlanEditView(parent, logger=None, **kwargs)

View is a kind of abstract widget that can hold another widgets. Remembers the order, so therefore it can function like a form with defined filling order.

It looks like this:

class Login(View):
    user = SomeInputWidget('user')
    password = SomeInputWidget('pass')
    login = SomeButtonWidget('Log In')

    def a_method(self):
        do_something()

The view is usually instantiated with an instance of widgetastic.browser.Browser, which will then enable resolving of all of the widgets defined.

Parameters
  • parent – A parent View or widgetastic.browser.Browser

  • additional_context – If the view needs some context, for example - you want to check that you are on the page of user XYZ but you can also be on the page for user FOO, then you shall use the additional_context to pass in required variables that will allow you to detect this.

plan_name
date
start_time
duration
cancel
save
class airgun.views.rhai.AddPlanView(parent, logger=None, **kwargs)

Base view for Satellite pages

title
name
actions
rules_filter
cancel
save
property is_displayed

Overrides the Widget.is_displayed(). The difference is that if the view does not have the root locator, it assumes it is displayed.

Returns

bool

class airgun.views.rhai.PlanModalWindow(parent, logger=None, **kwargs)

View is a kind of abstract widget that can hold another widgets. Remembers the order, so therefore it can function like a form with defined filling order.

It looks like this:

class Login(View):
    user = SomeInputWidget('user')
    password = SomeInputWidget('pass')
    login = SomeButtonWidget('Log In')

    def a_method(self):
        do_something()

The view is usually instantiated with an instance of widgetastic.browser.Browser, which will then enable resolving of all of the widgets defined.

Parameters
  • parent – A parent View or widgetastic.browser.Browser

  • additional_context – If the view needs some context, for example - you want to check that you are on the page of user XYZ but you can also be on the page for user FOO, then you shall use the additional_context to pass in required variables that will allow you to detect this.

yes
cancel