Files
hiring-test-one/example/mock/.local-web-server.json
Lloyd Brookes ccaae1614c mocks v2
2015-11-24 11:46:47 +00:00

44 lines
851 B
JSON

{
"mocks": [
{
"route": "/one",
"response": {
"body": { "id": 1, "name": "whatever" }
}
},
{
"route": "/two",
"request": { "accepts": "xml" },
"response": {
"body": "<result id='2' name='whatever' />"
}
},
{
"route": "/three",
"targets": [
{
"request": { "method": "GET" },
"response": {
"body": { "id": 1, "name": "whatever" }
}
},
{
"request": { "method": "POST" },
"response": {
"status": 400,
"body": { "message": "That method is not allowed." }
}
}
]
},
{
"route": "/four",
"module": "/mocks/four.js"
},
{
"route": "/five/:id\\?name=:name",
"module": "/mocks/five.js"
}
]
}