old_contents: import requests
  import pytest
  
  def has_internet():
      '''Uses 8.8.8.8 to check connectivity'''
      try:
          requests.head('http://www.google.com', timeout=1)
          return True
      except requests.ConnectionError:
          return False
  
  needinternet=pytest.mark.skipif(not has_internet(), reason="This test needs internet")
  
new_contents: '''Fixture to skip tests that require internet access'''
  
  import requests
  import pytest
  
  def has_internet():
      '''Uses 8.8.8.8 to check connectivity'''
      try:
          requests.head('http://www.google.com', timeout=1)
          return True
      except requests.ConnectionError:
          return False
  
  needinternet=pytest.mark.skipif(not has_internet(), 
                                  reason="This test needs internet")
  
subject: Add docstring and fix line length for pytest_skipif