URL: https://github.com/freeipa/freeipa/pull/1999 Author: Rezney Title: #1999: ui_tests: fixes for issues with sending key and focus on element Action: opened
PR body: """ Fixes 2 issues in WebUI tests. One issue is that we are unable to confirm a dialog by "Enter" keyboard - "actions.click()" helps here to get focus on the page. Second issue is probbaly related to screen resolution as we cannot click to some of the action buttons (buttons which are having issue varies). """ To pull the PR as Git branch: git remote add ghfreeipa https://github.com/freeipa/freeipa git fetch ghfreeipa pull/1999/head:pr1999 git checkout pr1999
From 66e3e6016192283f48f019eda8ea81d14189927c Mon Sep 17 00:00:00 2001 From: Michal Reznik <mrez...@redhat.com> Date: Thu, 7 Jun 2018 12:25:49 +0200 Subject: [PATCH 1/2] ui_tests: fixes for issues with sending key and focus on element Fixes 2 issues in WebUI tests. One issue is that we are unable to confirm a dialog by "Enter" keyboard - "actions.click()" helps here to get focus on the page. Second issue is probbaly related to screen resolution as we cannot click to some of the action buttons (buttons which are having issue varies). https://pagure.io/freeipa/issue/7583 --- ipatests/test_webui/test_service.py | 1 + ipatests/test_webui/ui_driver.py | 1 + 2 files changed, 2 insertions(+) diff --git a/ipatests/test_webui/test_service.py b/ipatests/test_webui/test_service.py index 621ebe60cd..74cca36be4 100644 --- a/ipatests/test_webui/test_service.py +++ b/ipatests/test_webui/test_service.py @@ -592,6 +592,7 @@ def test_add_service_using_enter(self): pkey = self.get_service_pkey('smtp') self.add_service('smtp', confirm=False) actions = ActionChains(self.driver) + actions.click() actions.send_keys(Keys.ENTER).perform() self.wait(1) assert self.has_record(pkey) diff --git a/ipatests/test_webui/ui_driver.py b/ipatests/test_webui/ui_driver.py index 6a611f9c02..88774c64f7 100644 --- a/ipatests/test_webui/ui_driver.py +++ b/ipatests/test_webui/ui_driver.py @@ -1699,6 +1699,7 @@ def action_list_action(self, name, confirm=True, confirm_btn="ok", expand.click() action_link = self.find("li[data-name=%s] a" % name, By.CSS_SELECTOR, context, strict=True) + self.move_to_element_in_page(action_link) action_link.click() if confirm: self.wait(0.5) # wait for dialog From 3e475642508f99f990d70313efa1109088a4b2a8 Mon Sep 17 00:00:00 2001 From: Michal Reznik <mrez...@redhat.com> Date: Thu, 7 Jun 2018 12:36:31 +0200 Subject: [PATCH 2/2] TEMP_COMMIT: activate UI tests --- .freeipa-pr-ci.yaml | 176 +++++++--------------------------------------------- 1 file changed, 23 insertions(+), 153 deletions(-) diff --git a/.freeipa-pr-ci.yaml b/.freeipa-pr-ci.yaml index 21f1c004d7..c625f06ffb 100644 --- a/.freeipa-pr-ci.yaml +++ b/.freeipa-pr-ci.yaml @@ -3,6 +3,9 @@ topologies: name: build cpu: 2 memory: 3800 + ipaserver: &ipaserver + name: ipaserver + cpu: 1 master_1repl: &master_1repl name: master_1repl cpu: 4 @@ -27,183 +30,50 @@ jobs: timeout: 1800 topology: *build - fedora-28/simple_replication: + fedora-28/test_webui_a_to_d: requires: [fedora-28/build] priority: 50 job: - class: RunPytest + class: RunWebuiTests args: build_url: '{fedora-28/build_url}' - test_suite: test_integration/test_simple_replication.py + test_suite: test_webui/test_automember.py test_webui/test_cert.py test_webui/test_config.py test_webui/test_delegation.py test_webui/test_dns.py template: *ci-master-f28 - timeout: 3600 - topology: *master_1repl + timeout: 7200 + topology: *ipaserver - fedora-28/caless: + fedora-28/test_webui_g_to_m: requires: [fedora-28/build] priority: 50 job: - class: RunPytest + class: RunWebuiTests args: build_url: '{fedora-28/build_url}' - test_suite: test_integration/test_caless.py::TestServerReplicaCALessToCAFull + test_suite: test_webui/test_group.py test_webui/test_hbac.py test_webui/test_host.py test_webui/test_hostgroup.py test_webui/test_idviews.py test_webui/test_krbtpolicy.py test_webui/test_misc_cases.py template: *ci-master-f28 - timeout: 3600 - topology: *master_1repl + timeout: 7200 + topology: *ipaserver - fedora-28/external_ca: + fedora-28/test_webui_n_to_r: requires: [fedora-28/build] priority: 50 job: - class: RunPytest + class: RunWebuiTests args: build_url: '{fedora-28/build_url}' - test_suite: test_integration/test_external_ca.py::TestExternalCA test_integration/test_external_ca.py::TestSelfExternalSelf test_integration/test_external_ca.py::TestExternalCAInstall + test_suite: test_webui/test_navigation.py test_webui/test_netgroup.py test_webui/test_pwpolicy.py test_webui/test_range.py test_webui/test_rbac.py test_webui/test_realmdomains.py template: *ci-master-f28 - timeout: 3600 - topology: *master_1repl_1client + timeout: 7200 + topology: *ipaserver - fedora-28/test_topologies: + fedora-28/test_webui_s_to_z: requires: [fedora-28/build] priority: 50 job: - class: RunPytest + class: RunWebuiTests args: build_url: '{fedora-28/build_url}' - test_suite: test_integration/test_topologies.py + test_suite: test_webui/test_selfservice.py test_webui/test_selinuxusermap.py test_webui/test_service.py test_webui/test_sudo.py test_webui/test_trust.py test_webui/test_user.py test_webui/test_vault.py template: *ci-master-f28 - timeout: 3600 - topology: *master_1repl - - fedora-28/test_sudo: - requires: [fedora-28/build] - priority: 50 - job: - class: RunPytest - args: - build_url: '{fedora-28/build_url}' - test_suite: test_integration/test_sudo.py - template: *ci-master-f28 - timeout: 3600 - topology: *master_1repl_1client - - fedora-28/test_commands: - requires: [fedora-28/build] - priority: 50 - job: - class: RunPytest - args: - build_url: '{fedora-28/build_url}' - test_suite: test_integration/test_commands.py - template: *ci-master-f28 - timeout: 3600 - topology: *master_1repl - - fedora-28/test_kerberos_flags: - requires: [fedora-28/build] - priority: 50 - job: - class: RunPytest - args: - build_url: '{fedora-28/build_url}' - test_suite: test_integration/test_kerberos_flags.py - template: *ci-master-f28 - timeout: 3600 - topology: *master_1repl_1client - - fedora-28/test_http_kdc_proxy: - requires: [fedora-28/build] - priority: 50 - job: - class: RunPytest - args: - build_url: '{fedora-28/build_url}' - test_suite: test_integration/test_http_kdc_proxy.py - template: *ci-master-f28 - timeout: 3600 - topology: *master_1repl_1client - - fedora-28/test_forced_client_enrolment: - requires: [fedora-28/build] - priority: 50 - job: - class: RunPytest - args: - build_url: '{fedora-28/build_url}' - test_suite: test_integration/test_forced_client_reenrollment.py - template: *ci-master-f28 - timeout: 3600 - topology: *master_1repl_1client - - fedora-28/test_advise: - requires: [fedora-28/build] - priority: 50 - job: - class: RunPytest - args: - build_url: '{fedora-28/build_url}' - test_suite: test_integration/test_advise.py - template: *ci-master-f28 - timeout: 3600 - topology: *master_1repl - - fedora-28/test_testconfig: - requires: [fedora-28/build] - priority: 50 - job: - class: RunPytest - args: - build_url: '{fedora-28/build_url}' - test_suite: test_integration/test_testconfig.py - template: *ci-master-f28 - timeout: 3600 - topology: *master_1repl - - fedora-28/test_service_permissions: - requires: [fedora-28/build] - priority: 50 - job: - class: RunPytest - args: - build_url: '{fedora-28/build_url}' - test_suite: test_integration/test_service_permissions.py - template: *ci-master-f28 - timeout: 3600 - topology: *master_1repl - - fedora-28/test_netgroup: - requires: [fedora-28/build] - priority: 50 - job: - class: RunPytest - args: - build_url: '{fedora-28/build_url}' - test_suite: test_integration/test_netgroup.py - template: *ci-master-f28 - timeout: 3600 - topology: *master_1repl - - fedora-28/test_vault: - requires: [fedora-28/build] - priority: 50 - job: - class: RunPytest - args: - build_url: '{fedora-28/build_url}' - test_suite: test_integration/test_vault.py - template: *ci-master-f28 - timeout: 4500 - topology: *master_1repl - - fedora-28/test_authconfig: - requires: [fedora-28/build] - priority: 50 - job: - class: RunPytest - args: - build_url: '{fedora-28/build_url}' - test_suite: test_integration/test_authselect.py - template: *ci-master-f28 - timeout: 3600 - topology: *master_1repl_1client - + timeout: 7200 + topology: *ipaserver
_______________________________________________ FreeIPA-devel mailing list -- freeipa-devel@lists.fedorahosted.org To unsubscribe send an email to freeipa-devel-le...@lists.fedorahosted.org Fedora Code of Conduct: https://getfedora.org/code-of-conduct.html List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedoraproject.org/archives/list/freeipa-devel@lists.fedorahosted.org/message/QIJCP24O432COLSJMNGYFZY2BPIPWB2U/