shmock icon indicating copy to clipboard operation
shmock copied to clipboard

Simple HTTP Mocking Library

Results 7 shmock issues
Sort by recently updated
recently updated
newest added

Support to mock an url and reply different things acording to the query. ``` mock.post("/get_query") .query({total: 10, limit: 1}) .query({foo: "bar"}) .reply(200, {name: "clark"}); mock.post("/get_query") .query({foo: "bar"}) .reply(200, {name: "kent"});...

This satisfies issue https://github.com/xetorthio/shmock/issues/2 and IMO is a generally useful addition to the package.

- Update to express 4.x. - Solved a problem with the use of multiple call with same path, added a test to show the problem.

from/related to #13 For example you could do: mock.get('/foo').set('Authorization', '123456').reply(401).set('WWW-Authenticate', 'Basic realm=foobar');

I used shmock to mock requests to a legacy library during some integration tests and I needed to inspect the received request in order to get the value of some...