From e6b021da4c7f58943c9bc5d5d4905ab655128973 Mon Sep 17 00:00:00 2001 From: Lars Wirzenius Date: Sat, 9 Mar 2019 09:55:50 +0200 Subject: Add: test /status in yarns --- yarns/000.yarn | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/yarns/000.yarn b/yarns/000.yarn index 1c3f55e..57179bb 100644 --- a/yarns/000.yarn +++ b/yarns/000.yarn @@ -39,6 +39,11 @@ member, to update and retrieve it, and to search memberships. SCENARIO Manage memberships GIVEN An effiapi instance + + WHEN admin requests GET /status + THEN HTTP status is 200 + AND HTTP body matches { "resources": 0 } + WHEN admin requests POST /memb with body { "fullname": "James Bond" } THEN HTTP status is 201 AND the member id is ID @@ -74,6 +79,9 @@ TODO: body = get_json_match() effiapi.POST('/memb', {}, body) + IMPLEMENTS WHEN admin requests GET /status + effiapi.GET('/status', {}, None) + IMPLEMENTS WHEN admin requests GET /memb with header (\S+): (\S+) header = get_next_match() print('header', repr(header)) -- cgit v1.2.1