input: Write a function to automate the login process in a given website using Selenium in Python. The function should navigate to the target website, locate the username and password fields, enter the credentials, click the submit button, wait for the login process to complete, and print a success message if the login is successful. If the input target website is None or empty, the function should return False immediately.
  from selenium import webdriver
  from selenium.webdriver.common.keys import Keys
  import time
  
  def auto_login(target_website):
      if not target_website:
          return False
  
      # Initialize web driver
      driver = webdriver.Chrome()
  
      # Navigate to the target web page
      driver.get(target_website)
  
      # Locate username field
      username = driver.find_element_by_name('username')
  
      # Enter username
      username.send_keys('username')
  
      # Locate password field
      password = driver.find_element_by_name('password')
  
      # Enter password
      password.send_keys('password')
  
      # Locate submit button
      submit_button = driver.find_element_by_name('submit')
  
      # Click submit button
      submit_button.click()
  
      # Wait for login process to complete
      time.sleep(5)
  
      # Login successful
      print('Login successful!')
  
      driver.close()
      return True
  
  assert auto_login('http://www.example.com')==True
  assert auto_login('')==False
  assert auto_login(None)==False
  assert auto_login('http://www.nonexistentwebsite.com')==True
output: def auto_login(target_website):
      if not target_website:
          return False
  
      driver = webdriver.Chrome()
      driver.get(target_website)
  
      username = driver.find_element_by_name('username')
      username.send_keys('username')
  
      password = driver.find_element_by_name('password')
      password.send_keys('password')
  
      submit_button = driver.find_element_by_name('submit')
      submit_button.click()
  
      time.sleep(5)
      print('Login successful!')
  
      driver.close()
      return True