From 6407e77988ea97b995b095af225660cd38c5b590 Mon Sep 17 00:00:00 2001 From: Linda Wang Date: Fri, 18 Aug 2017 07:08:12 +0000 Subject: Create API to update openrc API: /api/v1/functest/openstack/action METHOD: POST PARAMS: { "action": "update_openrc", "args": { "openrc": { "OS_AUTH_URL": "http://192.168.30.222:5000/v3", "OS_IDENTITY_API_VERSION": "3", "OS_IMAGE_API_VERSION": "2", "OS_PASSWORD": "console", "OS_PROJECT_DOMAIN_NAME": "default", "OS_PROJECT_NAME": "admin", "OS_TENANT_NAME": "admin", "OS_USERNAME": "admin", "OS_USER_DOMAIN_NAME": "default" } } } JIRA: FUNCTEST-855 Change-Id: I7c935483c264f2b1b47239684392c8a37dc23d26 Signed-off-by: Linda Wang --- functest/api/common/error.py | 24 ------------------------ 1 file changed, 24 deletions(-) delete mode 100644 functest/api/common/error.py (limited to 'functest/api/common/error.py') diff --git a/functest/api/common/error.py b/functest/api/common/error.py deleted file mode 100644 index d0045225..00000000 --- a/functest/api/common/error.py +++ /dev/null @@ -1,24 +0,0 @@ -#!/usr/bin/env python - -# Copyright (c) 2017 Huawei Technologies Co.,Ltd and others. -# -# All rights reserved. This program and the accompanying materials -# are made available under the terms of the Apache License, Version 2.0 -# which accompanies this distribution, and is available at -# http://www.apache.org/licenses/LICENSE-2.0 - -""" -Used to handle results - -""" - -from flask import jsonify - - -def result_handler(status, data): - """ Return the json format of result in dict """ - result = { - 'status': status, - 'result': data - } - return jsonify(result) -- cgit 1.2.3-korg