stubborn-ws
Advanced tools
Comparing version 0.1.2 to 0.1.3
{ | ||
"name": "stubborn-ws", | ||
"version": "0.1.2", | ||
"description": "", | ||
"homepage": "https://github.com/ybonnefond/stubborn#stubborn", | ||
"main": "index.js", | ||
"keywords": "stubborn, test, test api, testing, testing web server, nock, dyson, jest, jasmine, mocha", | ||
"scripts": { | ||
"test": "jest", | ||
"test-ci": "mkdir -p coverage && yarn lint && jest --coverage --coverageReporters=lcov && cat ./coverage/lcov.info | coveralls", | ||
"lint": "eslint src", | ||
"doc": "jsdoc2md -f src/*.js > doc/API.md", | ||
"release": "yarn doc && yarn publish" | ||
}, | ||
"author": "", | ||
"license": "ISC", | ||
"devDependencies": { | ||
"coveralls": "^3.0.2", | ||
"eslint": "^5.3.0", | ||
"got": "^9.0.0", | ||
"jest": "^23.3.0", | ||
"jest-diff": "^23.2.0", | ||
"jsdoc-to-markdown": "^4.0.1" | ||
}, | ||
"jest": { | ||
"testEnvironment": "node", | ||
"collectCoverage": true, | ||
"coverageReporters": [ | ||
"html" | ||
], | ||
"coverageDirectory": "coverage", | ||
"collectCoverageFrom": [ | ||
"src/**/*.js" | ||
] | ||
}, | ||
"dependencies": { | ||
"body-parser": "^1.18.3", | ||
"lodash": "^4.17.10" | ||
} | ||
"name": "stubborn-ws", | ||
"version": "0.1.3", | ||
"description": "", | ||
"homepage": "https://github.com/ybonnefond/stubborn#stubborn", | ||
"main": "src/index.js", | ||
"keywords": "stubborn, test, test api, testing, testing web server, nock, dyson, jest, jasmine, mocha", | ||
"scripts": { | ||
"test": "jest", | ||
"test-ci": "mkdir -p coverage && yarn lint && jest --coverage --coverageReporters=lcov && cat ./coverage/lcov.info | coveralls", | ||
"lint": "eslint src", | ||
"doc": "jsdoc2md -f src/*.js > doc/API.md", | ||
"release": "yarn doc && yarn publish" | ||
}, | ||
"author": "", | ||
"license": "ISC", | ||
"devDependencies": { | ||
"coveralls": "^3.0.2", | ||
"eslint": "^5.3.0", | ||
"got": "^9.0.0", | ||
"jest": "^23.3.0", | ||
"jest-diff": "^23.2.0", | ||
"jsdoc-to-markdown": "^4.0.1" | ||
}, | ||
"jest": { | ||
"testEnvironment": "node", | ||
"collectCoverage": true, | ||
"coverageReporters": [ | ||
"html" | ||
], | ||
"coverageDirectory": "coverage", | ||
"collectCoverageFrom": [ | ||
"src/**/*.js" | ||
] | ||
}, | ||
"dependencies": { | ||
"body-parser": "^1.18.3", | ||
"lodash": "^4.17.10" | ||
} | ||
} |
@@ -32,10 +32,11 @@ # Stubborn | ||
Stubborn is a testing tool that let you **hot** load and unload routes into a webserver. | ||
Requests are **strictly** matched against routes definitions based on Method, Path, Query parameters, Headers and Body. | ||
If the request does not exactly match one route definition (ex: extra parameter, missing parameter, value does not match, etc), Stubborn will respond with a 501. | ||
Stubborn strictly matches requests against on route definitions using rules based on: | ||
- Method | ||
- Path | ||
- Query parameters | ||
- Headers | ||
- Body | ||
The very fact that Stubborn respond to the request validates that the parameters sent are the expected one, any change in the code that send the request will break the test. Any breaking change will be picked up by your test. | ||
Stubborn response headers and body can be hardcoded or defined using a template. | ||
```javascript | ||
@@ -42,0 +43,0 @@ describe('Test', () => { |
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
72371
143