+
-
"""
response = mock.Mock(text=html)
results = bing_videos.response(response)
self.assertEqual(type(results), list)
self.assertEqual(len(results), 1)
self.assertEqual(results[0]['title'], 'Title 1')
- self.assertEqual(results[0]['url'], 'https://url.com/1')
- self.assertEqual(results[0]['content'], 'Content 1')
- self.assertEqual(results[0]['thumbnail'], 'thumb_1.jpg')
-
- html = """
-
- """
- response = mock.Mock(text=html)
- results = bing_videos.response(response)
- self.assertEqual(type(results), list)
- self.assertEqual(len(results), 1)
- self.assertEqual(results[0]['title'], 'Title 1')
- self.assertEqual(results[0]['url'], 'https://url.com/1')
+ self.assertEqual(results[0]['url'], 'https://bing.com/video')
self.assertEqual(results[0]['content'], 'Content 1')
self.assertEqual(results[0]['thumbnail'], 'thumb_1.jpg')