diff options
author | 2016-05-26 06:39:07 +0000 | |
---|---|---|
committer | 2016-05-26 06:39:07 +0000 | |
commit | 2377f84d9142dad19bfabc795d3a5a73e3c67533 (patch) | |
tree | 80ca788cb1dfe5a6241a102c61c8eea26cd4d9d7 /utils/test/result_collection_api/result_collection_api.py | |
parent | 3942c39c0b7b460a40571b70b5647bf147b298b3 (diff) | |
parent | 119faa49c41ab093aaa9767e906b448198e5c6c4 (diff) |
Merge "attach version number to url in testAPI"
Diffstat (limited to 'utils/test/result_collection_api/result_collection_api.py')
-rw-r--r-- | utils/test/result_collection_api/result_collection_api.py | 25 |
1 files changed, 12 insertions, 13 deletions
diff --git a/utils/test/result_collection_api/result_collection_api.py b/utils/test/result_collection_api/result_collection_api.py index 704d6075c..97aa58c77 100644 --- a/utils/test/result_collection_api/result_collection_api.py +++ b/utils/test/result_collection_api/result_collection_api.py @@ -54,25 +54,25 @@ def make_app(): return tornado.web.Application( [ # GET /version => GET API version - (r"/version", VersionHandler), + (r"/versions", VersionHandler), # few examples: # GET /pods => Get all pods # GET /pods/1 => Get details on POD 1 - (r"/pods", PodHandler), - (r"/pods/([^/]+)", PodHandler), + (r"/api/v1/pods", PodHandler), + (r"/api/v1/pods/([^/]+)", PodHandler), # few examples: # GET /projects # GET /projects/yardstick - (r"/projects", ProjectHandler), - (r"/projects/([^/]+)", ProjectHandler), + (r"/api/v1/projects", ProjectHandler), + (r"/api/v1/projects/([^/]+)", ProjectHandler), # few examples # GET /projects/qtip/cases => Get cases for qtip # - (r"/projects/([^/]+)/cases", TestcaseHandler), - (r"/projects/([^/]+)/cases/([^/]+)", TestcaseHandler), + (r"/api/v1/projects/([^/]+)/cases", TestcaseHandler), + (r"/api/v1/projects/([^/]+)/cases/([^/]+)", TestcaseHandler), # (r"/test_cases/([^/]+)", TestCasesHandler), # new path to avoid a long depth @@ -81,18 +81,17 @@ def make_app(): # POST /results => # Push results with mandatory request payload parameters # (project, case, and pod) - (r"/results", TestResultsHandler), - (r"/results([^/]*)", TestResultsHandler), - (r"/results/([^/]*)", TestResultsHandler), + (r"/api/v1/results", TestResultsHandler), + (r"/api/v1/results([^/]*)", TestResultsHandler), + (r"/api/v1/results/([^/]*)", TestResultsHandler), # Method to manage Dashboard ready results # GET /dashboard?project=functest&case=vPing&pod=opnfv-jump2 # => get results in dasboard ready format # get /dashboard # => get the list of project with dashboard ready results - (r"/dashboard", DashboardHandler), - (r"/dashboard([^/]*)", DashboardHandler), - (r"/dashboard/([^/]*)", DashboardHandler), + (r"/dashboard/v1/results", DashboardHandler), + (r"/dashboard/v1/results([^/]*)", DashboardHandler), ], db=db, debug=CONF.api_debug_on, |