code: def test_locationiq_single_result():
      url = "https://locationiq.org/v1/search.php?q=Ottawa%2C+Ontario&format=json&limit=1&key=TEST_KEY"
      data_file = "tests/results/locationiq.json"
      with requests_mock.Mocker() as mocker, open(data_file, "r") as ip:
          mock_result = json.loads(ip.read())
          single_mock_result = json.dumps(mock_result[0:1])
          mocker.get(url, text=single_mock_result)
          g = geocoder.locationiq(location, key="TEST_KEY", maxRows=1)
          assert g.ok
          assert len(g) == 1
  
imports: import json
  import geocoder
  import requests_mock
label_desc: Use image node_id 2 for calling a global function with example usage: test_locationiq_single_result() without return types