input: Write a function to automate the login process in a given website using Selenium in Python. The function should navigate to the target web page, locate the username and password fields, enter credentials, click the submit button, and verify the success of the login process.
  assert automate_login("http://www.example.com", "username", "password")=='Login successful!'
  assert automate_login("http://www.anothersite.com", "testuser", "testpass")=='Login unsuccessful!'
  assert automate_login("http://www.example.org", "user", "pass")=='Login successful!'
  assert automate_login("http://www.testsite.com", "login", "pwd")=='Login unsuccessful!'
  assert automate_login("http://www.sample.com", "admin", "admin123")=='Login successful!'
output: def automate_login(url, username, password):
      from selenium import webdriver
      from selenium.webdriver.common.by import By
      from selenium.webdriver.common.keys import Keys
      import time
      
      driver = webdriver.Chrome()
      driver.get(url)
      
      try:
          username_field = driver.find_element(By.NAME, "username")
          password_field = driver.find_element(By.NAME, "password")
          submit_button = driver.find_element(By.NAME, "submit")
          
          username_field.send_keys(username)
          password_field.send_keys(password)
          submit_button.click()
          
          time.sleep(2)
          
          if "success" in driver.current_url:
              return 'Login successful!'
          else:
              return 'Login unsuccessful!'
      finally:
          driver.quit()