87 lines
2.3 KiB
YAML
87 lines
2.3 KiB
YAML
fixtures:
|
|
- AuthenticationFixture
|
|
|
|
defaults:
|
|
request_headers:
|
|
X-Auth-Token: $ENVIRON['OS_TOKEN']
|
|
|
|
tests:
|
|
- name: create software config
|
|
desc: d26d11c0-4924-11e8-842f-0ed5f89f718b
|
|
POST: /software_configs
|
|
request_headers:
|
|
content-type: application/json
|
|
data:
|
|
group: script
|
|
config: '#!/bin/sh -x\necho hello'
|
|
status: 200
|
|
|
|
- name: show config
|
|
desc: d26d149a-4924-11e8-842f-0ed5f89f718b
|
|
GET: $LAST_URL/$RESPONSE['software_config.id']
|
|
status: 200
|
|
response_json_paths:
|
|
$.software_config.group: script
|
|
|
|
- name: create software deployment
|
|
desc: d26d15ee-4924-11e8-842f-0ed5f89f718b
|
|
POST: /software_deployments
|
|
request_headers:
|
|
content-type: application/json
|
|
data:
|
|
action: ACTION0
|
|
config_id: $RESPONSE['software_config.id']
|
|
server_id: dummy_server
|
|
status: 200
|
|
|
|
- name: show deployment
|
|
desc: d26d1968-4924-11e8-842f-0ed5f89f718b
|
|
GET: $LAST_URL/$RESPONSE['software_deployment.id']
|
|
status: 200
|
|
response_json_paths:
|
|
$.software_deployment.action: ACTION0
|
|
|
|
- name: show deployment metadata
|
|
desc: d26d1ae4-4924-11e8-842f-0ed5f89f718b
|
|
GET: /software_deployments/metadata/$RESPONSE['software_deployment.server_id']
|
|
status: 200
|
|
response_json_paths:
|
|
$.metadata[0].group: script
|
|
|
|
- name: update deployment
|
|
desc: d26d1c1a-4924-11e8-842f-0ed5f89f718b
|
|
PUT: $HISTORY['show deployment'].$URL
|
|
request_headers:
|
|
content-type: application/json
|
|
data:
|
|
action: ACTION1
|
|
status: COMPLETE
|
|
status_reason: completed
|
|
status: 200
|
|
response_json_paths:
|
|
$.software_deployment.action: ACTION1
|
|
|
|
- name: list software configs
|
|
desc: d26d1d46-4924-11e8-842f-0ed5f89f718b
|
|
GET: /software_configs
|
|
status: 200
|
|
response_json_paths:
|
|
$.software_configs[?id = "$RESPONSE['software_deployment.config_id']"].group: script
|
|
|
|
- name: list software deployments
|
|
desc: d26d1e90-4924-11e8-842f-0ed5f89f718b
|
|
GET: /software_deployments
|
|
status: 200
|
|
response_json_paths:
|
|
$.software_deployments[?id= "$HISTORY['update deployment'].$RESPONSE['software_deployment.id']"].server_id: dummy_server
|
|
|
|
- name: delete deployment
|
|
desc: d26d1fda-4924-11e8-842f-0ed5f89f718b
|
|
DELETE: $HISTORY['show deployment'].$URL
|
|
status: 204
|
|
|
|
- name: delete config
|
|
desc: d26d22be-4924-11e8-842f-0ed5f89f718b
|
|
DELETE: $HISTORY['show config'].$URL
|
|
status: 204
|