mirror of
https://github.com/Telecominfraproject/wlan-testing.git
synced 2026-03-20 03:41:54 +00:00
Added webdriver wait
This commit is contained in:
@@ -1261,10 +1261,11 @@ def get_ip_address_and(request, WifiName, WifiPass, setup_perfectoMobile, connDa
|
||||
#Click on connect button
|
||||
# -------------------------------------------------------
|
||||
try:
|
||||
time.sleep(5)
|
||||
# time.sleep(5)
|
||||
report.step_start("Click Connect Button")
|
||||
print("Click Connect")
|
||||
joinBTNElement = driver.find_element_by_xpath("//*[@text='Connect']")
|
||||
joinBTNElement =WebDriverWait(driver, 10).until(
|
||||
EC.presence_of_element_located((MobileBy.XPATH, "//*[@text='Connect']']")))
|
||||
joinBTNElement.click()
|
||||
except NoSuchElementException:
|
||||
print("Connect Button Not Enabled...Verify if Password is set properly ")
|
||||
@@ -1568,8 +1569,9 @@ def get_ip_address_and(request, WifiName, WifiPass, setup_perfectoMobile, connDa
|
||||
# -------------------------------------------------------
|
||||
try:
|
||||
report.step_start("Click Connect Button")
|
||||
time.sleep(5)
|
||||
joinBTNElement = driver.find_element_by_xpath("//*[@text='Connect']")
|
||||
# time.sleep(5)
|
||||
joinBTNElement = WebDriverWait(driver, 10).until(
|
||||
EC.presence_of_element_located((MobileBy.XPATH, "//*[@text='Connect']']")))
|
||||
joinBTNElement.click()
|
||||
except NoSuchElementException:
|
||||
print("Connect Button Not Enabled...Verify if Password is set properly ")
|
||||
|
||||
Reference in New Issue
Block a user