def test_parse_apirespone(self): with open('fixtures/api_search.json') as f: apiresponse = f.read() bom_stripped = dreamfilm._strip_bom(apiresponse) items = dreamfilm._apiresponse_to_items(bom_stripped) self.assertEqual(len(items), 25)