input: Write a function to scrape a given website and return the scraped data in a structured format. The function should accept a URL as input and return a list of dictionaries containing the scraped information.
  
  def scrape_website(url):
      import requests
      from bs4 import BeautifulSoup
  
      page = requests.get(url)
      soup = BeautifulSoup(page.text, 'html.parser')
  
      # Example scraping code for demonstration
      titles = soup.find_all('h2')
      data = [{'title': title.get_text()} for title in titles]
  
      return data
  
  assert scrape_website('https://www.example.com') == [{'title': 'Example Domain'}]  # Example test case for demonstration
  assert scrape_website('https://www.anotherexample.com') == [{'title': 'Another Example'}]  # Example test case for demonstration
output: def scrape_website(url):
      import requests
      from bs4 import BeautifulSoup
  
      page = requests.get(url)
      soup = BeautifulSoup(page.text, 'html.parser')
  
      titles = soup.find_all('h2')
      data = [{'title': title.get_text()} for title in titles]
  
      return data