def test_get_dictionary(self): client = GoogleSearchResults({ "q": "Coffee", "location": "Austin,Texas" }) data = client.get_dictionary() self.assertIsNotNone(data.get('local_results'))
def test_get_search_archive(self): client = GoogleSearchResults({ "q": "Coffee", "location": "Austin,Texas" }) search_result = client.get_dictionary() search_id = search_result.get("search_metadata").get("id") archived_search_result = GoogleSearchResults({}).get_search_archive( search_id, 'json') self.assertEqual( archived_search_result.get("search_metadata").get("id"), search_id)