def test_list_projects_server(self): from a2ml.api.a2ml_project import A2MLProject ctx = Context(path=os.path.join( os.environ.get('A2ML_PROJECT_PATH', ''), 'cli-integration-test'), debug=True) provider = "azure" ctx.config.set('providers', [provider]) ctx.config.set('use_server', True) A2MLProject(ctx, provider).list()
def select(ctx, provider, name): """Select Project. Name will be set in provider.yaml/project """ A2MLProject(ctx, provider).select(name)
def delete(ctx, provider, name): """Delete Project""" A2MLProject(ctx, provider).delete(name)
def create(ctx, provider, name): """Create Project""" A2MLProject(ctx, provider).create(name)
def list_cmd(ctx, provider): """List Projects""" A2MLProject(ctx, provider).list()
def select_project_task(params): return with_context( params, lambda ctx: A2MLProject(ctx, None).select( *params['args'], **params['kwargs']))
def func(ctx): res = A2MLProject(ctx, None).list(*params['args'], **params['kwargs']) return __map_collection_to_name(res, 'projects')