app/recipe/tests/test_recipe_api.py
def sample_recipe(user, **params):
    """create and return a sample recipe"""
    defaults={
        'title' : 'Sample recipe ',
        'time_minutes': 10,
        'price' : 5.00
    }

    defaults.update(params)

    return Recipe.objects.create(user = user, **defaults)
create and return a sample recipe
create and return a sample recipe
create and return a sample recipe
def sample_recipe(user, **params):
    defaults={
        'title' : 'Sample recipe ',
        'time_minutes': 10,
        'price' : 5.00
    }
    defaults.update(params)
    return Recipe.objects.create(user = user, **defaults)
def sample_recipe ( user , ** params ) : defaults = { 'title' : 'Sample recipe ' , 'time_minutes' : 10 , 'price' : 5.00 } defaults . update ( params ) return Recipe . objects . create ( user = user , ** defaults )
create and return a sample recipe
create and return a sample recipe
"""create and return a sample recipe"""
user