airgun.views.cloud_inventory

Module Contents

Classes

InventoryTab

Cloud Inventory Upload Tab element.

InventoryItemsView

Item related to one organization on Cloud Inventory Upload page.

CloudInventoryListView

Main RH Cloud Inventory Upload view.

class airgun.views.cloud_inventory.InventoryTab(parent, logger=None, **kwargs)

Cloud Inventory Upload Tab element.

This is lightweight subclass needed because Cloud Inventory Upload tabs contain icons, and widgetastic_patternfly Tab looks for exact match.

TAB_LOCATOR
child_widget_accessed(widget)

This hook is called when a child widget of current view is accessed.

One of useful examples is below. it allows us to switch between frames.

Parameters

widget – The widget being accessed or ParametrizedViewRequest.

class airgun.views.cloud_inventory.InventoryItemsView(parent=None, id=None, locator=None, logger=None)

Item related to one organization on Cloud Inventory Upload page.

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

Cloud Inventory Upload Tab element.

This is lightweight subclass needed because Cloud Inventory Upload tabs contain icons, and widgetastic_patternfly Tab looks for exact match.

process
restart
terminal
scheduled_run
class uploading(parent, logger=None, **kwargs)

Cloud Inventory Upload Tab element.

This is lightweight subclass needed because Cloud Inventory Upload tabs contain icons, and widgetastic_patternfly Tab looks for exact match.

process
download_report
terminal
ROOT = .//dl[contains(@class, "pf-c-accordion account-list")]
DESCRIPTION_LOCATOR = .//span[contains(@class, "pf-c-label pf-m-blue pf-m-outline account-icon")]
STATUS_ELEMENTS = .//div[contains(@class, "status")]/div[contains(@class, "item")]
property is_generating
property is_uploading
property status
property is_active
child_widget_accessed(widget)

This hook is called when a child widget of current view is accessed.

One of useful examples is below. it allows us to switch between frames.

Parameters

widget – The widget being accessed or ParametrizedViewRequest.

read(widget_names=None)

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

Returns

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

fill(values)

Implementation of form filling.

This method goes through all widgets defined on this view one by one and calls their fill methods appropriately.

None values will be ignored.

It will log any skipped fill items. It will log a warning if you pass any extra values for filling.

It will store the fill value in last_fill_data. The data will be “deflattened” to ensure uniformity.

Parameters

values – A dictionary of widget_name: value_to_fill.

Returns

bool if the fill changed any value.

class airgun.views.cloud_inventory.CloudInventoryListView(parent, logger=None, **kwargs)

Main RH Cloud Inventory Upload view.

title
auto_update
obfuscate_hostnames
obfuscate_ips
exclude_packages
cloud_connector
reconfigure_cloud_connector
sync_status
inventory_list
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().