diff --git a/airgun/entities/host_new.py b/airgun/entities/host_new.py index e10186d29..8e9df7f0e 100644 --- a/airgun/entities/host_new.py +++ b/airgun/entities/host_new.py @@ -43,7 +43,8 @@ def get_details(self, entity_name, widget_names=None): view = self.navigate_to(self, 'NewDetails', entity_name=entity_name) view.wait_displayed() self.browser.plugin.ensure_page_safe() - wait_for(lambda: view.ansible.roles.noRoleAssign.is_displayed, timeout=5) + # Run this read twice to navigate to the page and load it before reading + view.read(widget_names=widget_names) return view.read(widget_names=widget_names) def get_host_statuses(self, entity_name): @@ -420,7 +421,7 @@ def get_ansible_roles(self, entity_name): view = self.navigate_to(self, 'NewDetails', entity_name=entity_name) view.wait_displayed() self.browser.plugin.ensure_page_safe() - wait_for(lambda: view.ansible.roles.is_displayed, timeout=5) + wait_for(lambda: view.ansible.roles.table.is_displayed, timeout=5) return view.ansible.roles.table.read() def get_ansible_roles_modal(self, entity_name):