airgun.views.dashboard

Module Contents

class airgun.views.dashboard.ItemValueList

Bases: widgetastic.widget.Widget

List of name-value pairs. Each name element from every pair is clickable

Example html representation:

<ul>
    <li>
        <a class="dashboard-links"...>Hosts with no reports</a>
        <h4>5</h4>
    </li>
LABELS = .//li/a[@class='dashboard-links']
LABEL = .//li/a[@class='dashboard-links'][normalize-space(.)='{}']
VALUE = .//h4[preceding-sibling::a[contains(., '{}')]]
read(self)

Return a dictionary where keys are widget criteria names and values are number of hosts that correspond to these criteria

fill(self, value)

Click on specific criteria from the widget list

class airgun.views.dashboard.TotalCount

Bases: widgetastic.widget.Widget

Return total hosts count from Host Configuration Status type of widgets

total_count
read(self)

Return hosts count from widget. Usually it is a string like ‘Total Hosts: 5’

class airgun.views.dashboard.AutoRefresh

Bases: widgetastic.widget.Widget

Widget refer to auto refresh functionality on dashboard

AUTO_REFRESH = //a[contains(@href, '/?auto_refresh')]
read(self)

Return whether functionality is enabled or disabled

fill(self, value)

Click on a button if state of the widget need to be changed

class airgun.views.dashboard.DashboardView

Bases: airgun.views.common.BaseLoggedInView

class DiscoveredHosts

Bases: widgetastic.widget.View

ROOT = .//li[@data-name='Discovered Hosts']
hosts
hosts_count
class HostConfigurationStatus

Bases: widgetastic.widget.View

ROOT = .//li[@data-name='Host Configuration Status for All']
status_list
total_count
class TaskStatus

Bases: widgetastic.widget.View

ROOT = .//li[@data-name='Task Status']
states
fill(self, values)
class HostConfigurationChart

Bases: widgetastic.widget.View

ROOT = .//li[@data-name='Host Configuration Chart for All']
chart
class ContentViews

Bases: widgetastic.widget.View

ROOT = .//li[@data-name='Content Views']
content_views
class SyncOverview

Bases: widgetastic.widget.View

ROOT = .//li[@data-name='Sync Overview']
syncs
class HostSubscription

Bases: widgetastic.widget.View

ROOT = .//li[@data-name='Host Subscription Status']
subscriptions
fill(self, values)
class SubscriptionStatus

Bases: widgetastic.widget.View

ROOT = .//li[@data-name='Subscription Status']
subscriptions
class LatestErrata

Bases: widgetastic.widget.View

ROOT = .//li[@data-name='Latest Errata']
erratas
class NewHosts

Bases: widgetastic.widget.View

ROOT = .//li[@data-name='New Hosts']
hosts
class HostCollections

Bases: widgetastic.widget.View

ROOT = .//li[@data-name='Host Collections']
collections
class LatestFailedTasks

Bases: widgetastic.widget.View

ROOT = .//li[@data-name='Latest Warning/Error Tasks']
tasks
fill(self, values)
class VirtWhoConfigStatus

Bases: widgetastic.widget.View

ROOT = .//li[@data-name='Virt-who Configs Status']
config_status
latest_config
title
manage
refresh
searchbox
is_displayed
search(self, query)

Return whole dashboard view as a result of a search

Parameters:query (str) – search query to type into search field.
Returns:all view widgets values
Return type:dict