diff --git a/airgun/entities/contentview_new.py b/airgun/entities/contentview_new.py index 6007da6c0..8ff2fe038 100644 --- a/airgun/entities/contentview_new.py +++ b/airgun/entities/contentview_new.py @@ -129,6 +129,12 @@ def read_french_lang_cv(self): view.wait_displayed() return view.table.read() + def click_version_dropdown(self, entity_name, version, dropdown_option): + """Clicks a specific dropdown option for a CV Version""" + view = self.navigate_to(self, 'Version', entity_name=entity_name, version=version) + self.browser.plugin.ensure_page_safe(timeout='5s') + return view.version_dropdown.item_select(dropdown_option) + @navigator.register(NewContentViewEntity, 'All') class ShowAllContentViewsScreen(NavigateStep): diff --git a/airgun/views/contentview_new.py b/airgun/views/contentview_new.py index c6db5fbdb..7f6ff8c7b 100644 --- a/airgun/views/contentview_new.py +++ b/airgun/views/contentview_new.py @@ -19,6 +19,7 @@ ActionsDropdown, ConfirmationDialog, EditableEntry, + Pf4ActionsDropdown, PF4ProgressBar, PF4Search, ReadOnlyEntry, @@ -279,6 +280,7 @@ class ContentViewVersionDetailsView(BaseLoggedInView): promoteButton = PF4Button( locator='.//button[@data-ouia-component-id="cv-details-publish-button"]' ) + version_dropdown = Dropdown(locator='.//div[@data-ouia-component-id="cv-version-header-actions-dropdown"]') editDescription = PF4Button( locator='.//button[@data-ouia-component-id="edit-button-description"]' )