Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TEN-1442 / 13.3-RC1 / Fix missing web_driver in conftest.py #10280

Merged
merged 1 commit into from
Jul 3, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 10 additions & 5 deletions tests/bdd/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -227,27 +227,32 @@ def disable_ldap():
web_driver.find_element_by_xpath('//mat-list-item[@ix-auto="option__LDAP"]').click()
assert wait_on_element(web_driver, 5, '//li[span/a/text()="LDAP"]')
assert wait_on_element(web_driver, 5, '//div[contains(.,"Server Credentials")]')
wait_on_element(5, '//mat-checkbox[@ix-auto="checkbox__Enable"]', 'clickable')
value_exist = attribute_value_exist(web_driver, '//mat-checkbox[@ix-auto="checkbox__Enable"]', 'class', 'mat-checkbox-checked')
assert wait_on_element(web_driver, 5, '//mat-checkbox[@ix-auto="checkbox__Enable"]', 'clickable')
value_exist = attribute_value_exist(
web_driver,
'//mat-checkbox[@ix-auto="checkbox__Enable"]',
'class',
'mat-checkbox-checked'
)
if value_exist:
web_driver.find_element_by_xpath('//mat-checkbox[@ix-auto="checkbox__Enable"]').click()
wait_on_element(5, '//button[@ix-auto="button__SAVE"]', 'clickable')
wait_on_element(web_driver, 5, '//button[@ix-auto="button__SAVE"]', 'clickable')
web_driver.find_element_by_xpath('//button[@ix-auto="button__SAVE"]').click()
assert wait_on_element_disappear(web_driver, 60, '//h6[contains(.,"Please wait")]')
assert wait_on_element(web_driver, 7, '//div[contains(.,"Settings saved.")]')


def disable_nis():
"""click on Directory Services and select NIS, then disable NIS."""
assert wait_on_element(5, xpaths.sideMenu.directory_services, 'clickable')
assert wait_on_element(web_driver, 5, xpaths.sideMenu.directory_services, 'clickable')
web_driver.find_element_by_xpath(xpaths.sideMenu.directory_services).click()
assert wait_on_element(web_driver, 7, xpaths.sideMenu.directory_services_nis)
web_driver.find_element_by_xpath(xpaths.sideMenu.directory_services_nis).click()
assert wait_on_element(web_driver, 5, '//li[span/a/text()="NIS"]')
assert wait_on_element(web_driver, 5, '//h4[contains(.,"Network Information Service (NIS)")]')
assert wait_on_element(web_driver, 5, xpaths.checkbox.enable, 'clickable')
web_driver.find_element_by_xpath(xpaths.checkbox.enable).click()
assert wait_on_element(5, xpaths.button.save, 'clickable')
assert wait_on_element(web_driver, 5, xpaths.button.save, 'clickable')
web_driver.find_element_by_xpath(xpaths.button.save).click()
assert wait_on_element_disappear(web_driver, 30, xpaths.popup.please_wait)
assert wait_on_element(web_driver, 7, '//div[contains(.,"Settings saved.")]')
Loading