migration/create_recipes.py
author Julien Cristau <julien.cristau@logilab.fr>
Mon, 13 Apr 2015 11:12:49 +0200
changeset 1825 b859e64fc3ee
parent 802 e08097e621ee
permissions -rw-r--r--
Move setting of TestExecution.{options,execution_of} to a hook (closes #5242517) Apart from the 'archive' setting, they're inherited from the ProjectEnvironment and/or TestConfig. Make 'archive' a separate attribute instead.

from cubes.apycot import recipes

rql('DELETE Recipe R', ask_confirm=False)

for recipe in dir(recipes):
    if recipe.startswith('create_'):
        print recipe
        getattr(recipes, recipe)(session)

# define new recipes for current test config
rql('SET X use_recipe Y WHERE X name "quick", Y name "apycot.recipe.quick"')
rql('SET X use_recipe Y WHERE X name "full", Y name "apycot.recipe.full"')

commit()