Commit 728f6465 authored by Caleb Weeks's avatar Caleb Weeks

wip

parent a003ad78
module.exports = {
"res": {
"statusCode": 200,
"headers": "some headers"
},
"data": {
"exists": false
}
}
\ No newline at end of file
module.exports = {
"res": {
"statusCode": 200,
"headers": "some headers"
},
"data": {
"exists": true
}
}
\ No newline at end of file
module.exports = {
"res": {
"statusCode": 200,
"headers": "some headers"
},
"data": {
"exists": true
}
}
\ No newline at end of file
......@@ -2,7 +2,7 @@ module.exports = jest.fn(function (reqOptions, reqCallback) {
let testUri = reqOptions.uri;
let uriParts = testUri.split('/');
let fixturesIndex = uriParts.indexOf('__fixtures__');
uriParts.splice(fixturesIndex + 1, 0, 'requests');
uriParts.splice(fixturesIndex + 1, 0, 'request');
const test = require(uriParts.join('/'));
reqCallback(test.err ? test.err : null, test.res, JSON.stringify(test.data));
})
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment