diff --git a/Rest.http b/Rest.http index 9526c70..5c96baa 100644 --- a/Rest.http +++ b/Rest.http @@ -22,7 +22,33 @@ GET /products?unit_price=is.null ?? body length == 0 ### +GET /products?product_name=in.(Chai,Chang) +?? status == 200 +?? body length == 3 +{{ + const {expect} = require('chai'); + let responseItems = JSON.parse(response.body); + test("OK in", () => + { + expect(responseItems[0].id).to.equal(1); + expect(responseItems[2].id).to.equal(3); + }) +}} +### +GET /products?id=in.(1,2,79) +?? status == 200 +?? body length == 2 +{{ + const {expect} = require('chai'); + let responseItems = JSON.parse(response.body); + test("OK in", () => + { + expect(responseItems[0].id).to.equal(1); + expect(responseItems[1].id).to.equal(2); + }) +}} +### POST /products Content-Type: application/json