Answer the question
In order to leave comments, you need to log in
Why is there an error in the console when I try to run a test?
Just started learning Python and automation in general. What have I done wrong?
error:
driver = self.driver
__________________ ^
TabError: inconsistent use of tabs and spaces in indentation
code:
def test_pywebdrived_client_reg(self):
driver = self.driver
driver.get("http://random:81")
code = driver.find_element_by_id("`agent_code`").text
title = driver.find_element_by_id("`title`").text
fname = driver.find_element_by_id("`fname`").text
lname = driver.find_element_by_id("`lname`").text
company = driver.find_element_by_id("`com_name`").text
random_id = round(random.random()*1000000+random.random()*1000000)
random_id = str(random_id)
domain = 'autotest'+random_id
email = 'autotest'+random_id+'@mailinator.com'
password = driver.find_element_by_id("`pass`").text
phone = driver.find_element_by_id("`phone`").text
str_adr = driver.find_element_by_id("`str_adr`").text
city = driver.find_element_by_id("`city`").text
state = driver.find_element_by_id("`state`").text
zip = driver.find_element_by_id("`zip`").text
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question