Can anyone help me with Zomato login test script using Python Selenium Webdriver?

0 votes
Can anyone help me with Zomato login test script using Python Selenium Webdriver?
Jul 29, 2019 in Selenium by Laxmikant
349 views

1 answer to this question.

0 votes

Hi Laxmikant, if you want to write an automation test script to test Zomato's login functionality, you can use following sample code for the help:

from selenium import webdriver
import time

browser = webdriver.Chrome("C:\Program Files (x86)\Google\Chrome\chromedriver.exe")

browser.maximize_window()

browser.get('https://www.zomato.com / ncr')

time.sleep(3)

username = "test"
password = "test"
browser.find_element_by_xpath("//a[@id ='signin-link']").click()
time.sleep(2)

browser.find_element_by_xpath("//a[@id ='login-email']").click()

user = browser.find_element_by_xpath("//input[@id ='ld-email']")
user.send_keys(username)

pass = browser.find_element_by_xpath("//input[@id ='ld-password']")
pass.send_keys(password)

browser.find_element_by_xpath("//input[@id ='ld-submit-global']").click()

print('Login Successful')
browser.close()
answered Jul 29, 2019 by Anvi
• 14,010 points

Related Questions In Selenium

0 votes
2 answers

Can anyone help me that how to run Selenium WebDriver test cases in Chrome?

You first need to download chrome driver ...READ MORE

answered Aug 26, 2019 in Selenium by Abha
• 27,800 points
483 views
0 votes
1 answer
0 votes
1 answer
0 votes
1 answer

Installing Selenium Webdriver with Python package

Hey Hemant, for installing Selenium Webdriver with ...READ MORE

answered May 8, 2019 in Selenium by Anvi
• 14,010 points
680 views
0 votes
1 answer

Finding WebDriver element with Class Name in java

The better way to handle this element ...READ MORE

answered Apr 10, 2018 in Selenium by nsv999
• 5,510 points
2,218 views
0 votes
1 answer
0 votes
1 answer

Geo-location microphone camera pop up

To Allow or Block the notification, access using Selenium and you have to ...READ MORE

answered May 11, 2018 in Selenium by Samarpit
• 5,870 points
1,828 views
+1 vote
1 answer
0 votes
1 answer