blob: 47ff25f5372119066204ed16446594bf4c3821ac [file] [log] [blame]
fujinhuadcb405e2017-09-06 16:43:41 +08001*** settings ***
2Library Collections
3Library RequestsLibrary
4Library OperatingSystem
5Library json
6
7*** Variables ***
8@{return_ok_list}= 200 201 202
9${queryswagger_url} /api/vnflcm/v1/swagger.json
10
11*** Test Cases ***
fujinhua441febc2017-09-08 13:58:29 +080012VnflcmSwaggerTest
13 [Documentation] query swagger info vnflcm
14 ${headers} Create Dictionary Content-Type=application/json Accept=application/json
15 Create Session web_session http://${VNFLCM_IP}:8801 headers=${headers}
16 ${resp}= Get Request web_session ${queryswagger_url}
17 ${responese_code}= Convert To String ${resp.status_code}
18 List Should Contain Value ${return_ok_list} ${responese_code}
19 ${response_json} json.loads ${resp.content}
20 ${swagger_version}= Convert To String ${response_json['swagger']}
21 Should Be Equal ${swagger_version} 2.0