diff options
author | Serena Feng <feng.xiaowei@zte.com.cn> | 2018-03-16 06:20:25 +0000 |
---|---|---|
committer | Gerrit Code Review <gerrit@opnfv.org> | 2018-03-16 06:20:25 +0000 |
commit | d75376d833b0d42eb6e57d4915c89c94d9379047 (patch) | |
tree | 51084ad73e63ba5039e78a0fdc7191e928081971 /testapi/opnfv_testapi/handlers | |
parent | ee7a7b89092390ad91f71cc90409cce8f3dfe936 (diff) | |
parent | 46126a761681cf5ae4bd98f20916048db3cd278e (diff) |
Merge "delete useless trust_indicator in result model"
Diffstat (limited to 'testapi/opnfv_testapi/handlers')
-rw-r--r-- | testapi/opnfv_testapi/handlers/result_handlers.py | 24 |
1 files changed, 0 insertions, 24 deletions
diff --git a/testapi/opnfv_testapi/handlers/result_handlers.py b/testapi/opnfv_testapi/handlers/result_handlers.py index 74acb2e..edcac6e 100644 --- a/testapi/opnfv_testapi/handlers/result_handlers.py +++ b/testapi/opnfv_testapi/handlers/result_handlers.py @@ -48,8 +48,6 @@ class GenericResultHandler(base_handlers.GenericApiHandler): period = datetime.now() - timedelta(days=v) obj = {"$gte": str(period)} query['start_date'] = obj - elif k == 'trust_indicator': - query[k + '.current'] = float(v) elif k == 'from': date_range.update({'$gte': str(v)}) elif k == 'to': @@ -108,8 +106,6 @@ class ResultsCLHandler(GenericResultHandler): - to : ending time in 2016-01-01 or 2016-01-01 00:01:23 - scenario : the test scenario (previously version) - criteria : the global criteria status passed or failed - - trust_indicator : evaluate the stability of the test case - to avoid running systematically long and stable test case GET /results/project=functest&case=vPing&version=Arno-R1 \ &pod=pod_name&period=15 @@ -168,10 +164,6 @@ class ResultsCLHandler(GenericResultHandler): @type page: L{int} @in page: query @required page: False - @param trust_indicator: must be float - @type trust_indicator: L{float} - @in trust_indicator: query - @required trust_indicator: False @param descend: true, newest2oldest; false, oldest2newest @type descend: L{string} @in descend: query @@ -228,19 +220,3 @@ class ResultsGURHandler(GenericResultHandler): query = dict() query["_id"] = objectid.ObjectId(result_id) self._get_one(query=query) - - @swagger.operation(nickname="updateTestResultById") - def put(self, result_id): - """ - @description: update a single result by _id - @param body: fields to be updated - @type body: L{ResultUpdateRequest} - @in body: body - @rtype: L{Result} - @return 200: update success - @raise 404: result not exist - @raise 403: nothing to update - """ - query = {'_id': objectid.ObjectId(result_id)} - db_keys = [] - self._update(query=query, db_keys=db_keys) |