input: Write a function to create a Selenium script in Python to automate the login process in a given website. The function should initialize a web driver, navigate to the target website, locate and input the username and password, click the submit button, and wait for the login process to complete. If the login is successful, it should print "Login successful!".
  
  
  def automate_login(url, username_input, password_input, username_field, password_field, submit_button_field):
      from selenium import webdriver
      from selenium.webdriver.common.keys import Keys
      import time
  
      # Initialize web driver
      driver = webdriver.Chrome()
  
      # Navigate to the target web page
      driver.get(url)
  
      # Locate username field
      username = driver.find_element_by_name(username_field)
  
      # Enter username
      username.send_keys(username_input)
  
      # Locate password field
      password = driver.find_element_by_name(password_field)
  
      # Enter password
      password.send_keys(password_input)
  
      # Locate submit button
      submit_button = driver.find_element_by_name(submit_button_field)
  
      # Click submit button
      submit_button.click()
  
      # Wait for login process to complete
      time.sleep(5)
  
      # Login successful
      print('Login successful!')
  
      driver.close()
  
  assert automate_login('http://www.example.com', 'username', 'password', 'username', 'password', 'submit') == None
  
output: def automate_login(url, username_input, password_input, username_field, password_field, submit_button_field):
      from selenium import webdriver
      from selenium.webdriver.common.keys import Keys
      import time
  
      driver = webdriver.Chrome()
      driver.get(url)
      username = driver.find_element_by_name(username_field)
      username.send_keys(username_input)
      password = driver.find_element_by_name(password_field)
      password.send_keys(password_input)
      submit_button = driver.find_element_by_name(submit_button_field)
      submit_button.click()
      time.sleep(5)
      print('Login successful!')
      driver.close()