input: Write a function to automate login to a website using Selenium WebDriver.
  assert login_to_website('http://www.example.com', 'username', 'password')=='Login successful!'
  assert login_to_website('http://www.example.com', 'wrong_username', 'wrong_password')=='Login failed'
output: def login_to_website(url, username, password):
      from selenium import webdriver
      from selenium.webdriver.common.by import By
      from selenium.webdriver.common.keys import Keys
      from selenium.webdriver.chrome.service import Service
      from selenium.webdriver.chrome.options import Options
      from webdriver_manager.chrome import ChromeDriverManager
      import time
  
      options = Options()
      options.headless = True
      service = Service(ChromeDriverManager().install())
      driver = webdriver.Chrome(service=service, options=options)
  
      try:
          driver.get(url)
          
          username_field = driver.find_element(By.NAME, "username")
          password_field = driver.find_element(By.NAME, "password")
          login_button = driver.find_element(By.NAME, "login")
  
          username_field.send_keys(username)
          password_field.send_keys(password)
          login_button.click()
  
          time.sleep(3) # wait for login to process
  
          if "Login successful" in driver.page_source:
              return "Login successful!"
          else:
              return "Login failed"
      finally:
          driver.quit()