def test_product_list(self):
        self.response = self.get('product-list')
        self.response.assertStatusEqual(200)
        # we should have two products
        self.assertEqual(len(self.response.body), 2)
        # default we have 3 fields
        product = self.response.body[0]
        default_fields = ['id', 'url']
        for field in default_fields:
            self.assertIn(field, product)
Check if we get a list of products with the default attributes
dataset/ETHPy150Open django-oscar/django-oscar-api/oscarapi/tests/testproduct.py/ProductTest.test_product_list