summaryrefslogtreecommitdiff
path: root/spec/fixtures
diff options
context:
space:
mode:
authorPawel Chojnacki <pawel@chojnacki.ws>2017-04-24 19:55:07 +0200
committerPawel Chojnacki <pawel@chojnacki.ws>2017-04-24 19:55:07 +0200
commit5bf0441fd9cda2dcc3c3ef1ce3084df5ed87602d (patch)
tree7b6b8b17e2092284456760712c48ee3fdd106086 /spec/fixtures
parent88f69cbd8cd89ffbdc1f0200d5c298f7c7c0acd7 (diff)
downloadgitlab-ce-5bf0441fd9cda2dcc3c3ef1ce3084df5ed87602d.tar.gz
Cleanup deploymentsd controller spec and use schema validation to test the output
Diffstat (limited to 'spec/fixtures')
-rw-r--r--spec/fixtures/api/schemas/deployments.json58
1 files changed, 58 insertions, 0 deletions
diff --git a/spec/fixtures/api/schemas/deployments.json b/spec/fixtures/api/schemas/deployments.json
new file mode 100644
index 00000000000..1112f23aab2
--- /dev/null
+++ b/spec/fixtures/api/schemas/deployments.json
@@ -0,0 +1,58 @@
+{
+ "additionalProperties": false,
+ "properties": {
+ "deployments": {
+ "items": {
+ "additionalProperties": false,
+ "properties": {
+ "created_at": {
+ "type": "string"
+ },
+ "id": {
+ "type": "integer"
+ },
+ "iid": {
+ "type": "integer"
+ },
+ "last?": {
+ "type": "boolean"
+ },
+ "ref": {
+ "additionalProperties": false,
+ "properties": {
+ "name": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "name"
+ ],
+ "type": "object"
+ },
+ "sha": {
+ "type": "string"
+ },
+ "tag": {
+ "type": "boolean"
+ }
+ },
+ "required": [
+ "sha",
+ "created_at",
+ "iid",
+ "tag",
+ "last?",
+ "ref",
+ "id"
+ ],
+ "type": "object"
+ },
+ "minItems": 1,
+ "type": "array"
+ }
+ },
+ "required": [
+ "deployments"
+ ],
+ "type": "object"
+}