Comparing version 0.11.0 to 0.12.1
'use strict'; | ||
/* eslint-disable no-console */ | ||
const app = require('./server').app; | ||
const app = require('./app'); | ||
@@ -6,0 +6,0 @@ app.config = require('./config'); |
{ | ||
"name": "mockyeah", | ||
"version": "0.11.0", | ||
"version": "0.12.1", | ||
"description": "An invaluable service mocking platform built on Express.", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
@@ -11,2 +11,36 @@ 'use strict'; | ||
it('should not allow for more than one response type', () => { | ||
const payloadKeys = ['fixture', 'filePath', 'html', 'json', 'text']; | ||
const optionSets = [ | ||
{ | ||
fixture: './test/fixtures/some-data.json', | ||
filePath: './test/fixtures/some-data.csv' | ||
}, | ||
{ | ||
fixture: './test/fixtures/some-data.json', | ||
filePath: './test/fixtures/some-data.csv', | ||
html: '<body></body>' | ||
}, | ||
{ | ||
fixture: './test/fixtures/some-data.json', | ||
filePath: './test/fixtures/some-data.csv', | ||
html: '<body></body>', | ||
json: '{"test": "json"}' | ||
}, | ||
{ | ||
fixture: './test/fixtures/some-data.json', | ||
filePath: './test/fixtures/some-data.csv', | ||
html: '<body></body>', | ||
json: '{"test": "json"}', | ||
text: 'test text' | ||
} | ||
]; | ||
optionSets.forEach(optionSet => { | ||
expect(() => { | ||
mockyeah.get('/service/end/point', optionSet); | ||
}).to.throw('Response options must not include more than one of the following: ' + payloadKeys.join(', ')); | ||
}); | ||
}); | ||
describe('Status', () => { | ||
@@ -313,2 +347,2 @@ it('should return 404 for undeclared services', (done) => { | ||
}); | ||
}); | ||
}); |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
50751
38
945
3