input: Write a function to create a web scraper in Python that can extract hotel reviews from TripAdvisor. The function should define the URL and headers, make a request to the URL, parse the HTML, and extract the titles and texts of all reviews found in the HTML. Finally, the function should print each review's title and text, followed by a divider. If no reviews are found, the function should print an appropriate message.
  
  assert extract_hotel_reviews("<tripadvisor_url>") == "Extracted reviews and printed them."
  assert extract_hotel_reviews("<fake_url>") == "No reviews found or URL is invalid."
output: def extract_hotel_reviews(url):
      import requests
      from bs4 import BeautifulSoup
      
      headers = {
          'User-Agent': 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/58.0.3029.110 Safari/537.3'}
      
      try:
          response = requests.get(url, headers=headers)
          response.raise_for_status()
          soup = BeautifulSoup(response.text, 'html.parser')
          
          reviews = soup.find_all('div', class_='review-container')
          
          if not reviews:
              print("No reviews found or URL is invalid.")
              return "No reviews found or URL is invalid."
          
          for review in reviews:
              title = review.find('span', class_='noQuotes').text
              text = review.find('p', class_='partial_entry').text
              print(f"Title: {title}")
              print(f"Text: {text}")
              print("-" * 40)
          
          return "Extracted reviews and printed them."
      
      except requests.exceptions.RequestException:
          print("No reviews found or URL is invalid.")
          return "No reviews found or URL is invalid."