def setUp(self):
    self.client = APIClient()
    self.user = get_user_model().objects.create_user('example@example.com', 'testpass')
    self.client.force_authenticate(self.user)
    self.recipe = sample_recipe(user=self.user)
def setUp(self):
    self.client = APIClient()
    self.user = get_user_model().objects.create_user('example@example.com', 'testpass')
    self.client.force_authenticate(self.user)
    self.recipe = sample_recipe(user=self.user)