Beispiel #1
0
class FlavorAddView(FlavorView):
    @property
    def is_displayed(self):
        expected_title = "Add a new Flavor"
        return (self.in_availability_zones
                and self.entities.title.text == expected_title
                and self.entities.breadcrumb.active_location == expected_title)

    entities = View.nested(FlavorAddEntities)
    form = View.nested(FlavorAddForm)
class FlavorAllView(FlavorView):
    @property
    def is_displayed(self):
        return (self.in_availability_zones
                and self.entities.title.text == 'Flavors')

    toolbar = FlavorToolBar()
    entities = FlavorEntities()
    paginator = View.nested(PaginationPane)
Beispiel #3
0
class FlavorAllView(FlavorView):
    toolbar = FlavorToolBar()
    paginator = PaginationPane()
    search = View.nested(Search)
    including_entities = View.include(FlavorEntities, use_parent=True)

    @property
    def is_displayed(self):
        return (self.in_availability_zones
                and self.entities.title.text == 'Flavors')
Beispiel #4
0
class FlavorEditTagsView(FlavorView):
    @property
    def is_displayed(self):
        return (self.in_availability_zones
                and self.title.text == 'Tag Assignment'
                and '{} (Summary)'.format(
                    self.context['object'].name) in self.breadcrumb.locations)

    breadcrumb = BreadCrumb()
    title = Text('//div[@id="main-content"]//h3')
    entities = View.nested(BaseNonInteractiveEntitiesView)
    save = Button('Save')
    reset = Button('Reset')
    cancel = Button('Cancel')
Beispiel #5
0
class HostAggregatesAllView(HostAggregatesView):
    toolbar = HostAggregatesToolBar()
    paginator = PaginationPane()
    search = View.nested(Search)
    including_entities = View.include(HostAggregatesEntities, use_parent=True)

    @View.nested
    class my_filters(Accordion):  # noqa
        ACCORDION_NAME = "My Filters"

        navigation = BootstrapNav('.//div/ul')
        tree = ManageIQTree()

    @property
    def is_displayed(self):
        return (self.in_host_aggregates
                and self.entities.title.text == 'Host Aggregates')
Beispiel #6
0
class FlavorAllView(FlavorView):
    toolbar = FlavorToolBar()
    paginator = PaginationPane()
    search = View.nested(Search)
    including_entities = View.include(FlavorEntities, use_parent=True)

    @View.nested
    class my_filters(Accordion):  # noqa
        ACCORDION_NAME = "My Filters"

        navigation = BootstrapNav('.//div/ul')
        tree = ManageIQTree()

    @property
    def is_displayed(self):
        return (self.in_availability_zones
                and self.entities.title.text == 'Flavors')
Beispiel #7
0
class FlavorToolBar(View):
    policy = Dropdown('Policy')
    download = Dropdown('Download')
    configuration = Dropdown('Configuration')
    view_selector = View.nested(ItemsToolBarViewSelector)
Beispiel #8
0
class FlavorEntities(View):
    title = Text('//div[@id="main-content"]//h1')
    table = Table("//div[@id='gtl_div']//table")
    search = View.nested(Search)