summaryrefslogtreecommitdiff
path: root/yarns/300-workers.yarn
diff options
context:
space:
mode:
authorLars Wirzenius <liw@liw.fi>2017-10-16 19:00:20 +0300
committerLars Wirzenius <liw@liw.fi>2017-10-16 19:00:20 +0300
commit0238440bc56c7658feb658614644dd2223a86838 (patch)
tree9cf997dfa72a96ed50a154f343c1022e4444dc2e /yarns/300-workers.yarn
parent9ea6166068fd33b5fb3cec532ca14564c9b8673f (diff)
downloadick2-0238440bc56c7658feb658614644dd2223a86838.tar.gz
Add: /workers endpoint
Diffstat (limited to 'yarns/300-workers.yarn')
-rw-r--r--yarns/300-workers.yarn18
1 files changed, 9 insertions, 9 deletions
diff --git a/yarns/300-workers.yarn b/yarns/300-workers.yarn
index 473dd29..6386ae9 100644
--- a/yarns/300-workers.yarn
+++ b/yarns/300-workers.yarn
@@ -64,11 +64,11 @@ controller API. It doesn't actually talk to the worker itself.
WHEN user makes request GET /workers
THEN result has status code 200
- AND body matches { "projects": [] }
+ AND body matches { "workers": [] }
WHEN user makes request POST /workers
... {
- ... "workers": "obelix",
+ ... "worker": "obelix",
... "protocol": "ssh",
... "address": "obelix.ick.example",
... "user": "ick",
@@ -79,7 +79,7 @@ controller API. It doesn't actually talk to the worker itself.
THEN result has status code 201
AND body matches
... {
- ... "workers": "obelix",
+ ... "worker": "obelix",
... "protocol": "ssh",
... "address": "obelix.ick.example",
... "user": "ick",
@@ -93,9 +93,9 @@ controller API. It doesn't actually talk to the worker itself.
THEN result has status code 200
AND body matches
... {
- ... "projects": [
+ ... "workers": [
... {
- ... "workers": "obelix",
+ ... "worker": "obelix",
... "protocol": "ssh",
... "address": "obelix.ick.example",
... "user": "ick",
@@ -112,7 +112,7 @@ controller API. It doesn't actually talk to the worker itself.
THEN result has status code 200
AND body matches
... {
- ... "workers": "obelix",
+ ... "worker": "obelix",
... "protocol": "ssh",
... "address": "obelix.ick.example",
... "user": "ick",
@@ -123,7 +123,7 @@ controller API. It doesn't actually talk to the worker itself.
WHEN user makes request PUT /workers/obelix
... {
- ... "workers": "obelix",
+ ... "worker": "obelix",
... "protocol": "local",
... "keywords": {
... "debian_codename": "unstable"
@@ -132,7 +132,7 @@ controller API. It doesn't actually talk to the worker itself.
THEN result has status code 200
AND body matches
... {
- ... "workers": "obelix",
+ ... "worker": "obelix",
... "protocol": "local",
... "keywords": {
... "debian_codename": "unstable"
@@ -144,7 +144,7 @@ controller API. It doesn't actually talk to the worker itself.
THEN result has status code 200
AND body matches
... {
- ... "workers": "obelix",
+ ... "worker": "obelix",
... "protocol": "local",
... "keywords": {
... "debian_codename": "unstable"