0.0.1 • Published 4 years ago
@gugacavalieri/brief-js v0.0.1
brief-js
Brief is a validation tool that can help you assert your http web service migrations.
How to use it
- First install it using
npm
:
npm install -g @gugacavalieri/brief-js
- Create a config file (you can pass http headers if you like):
{
"domains": {
"new": "https://jsonplaceholder.typicode.com",
"old": "https://jsonplaceholder.typicode.com"
},
"http": {
"timeout": 10000,
"headers": {
"Authorization": "Bearer ..."
}
},
"endpoints": [
{ "method": "get", "url": "todos/1" }
]
}
- Run it!
brief-js --config config.json
It should print response codes as well as different outputs in the endpoints that you defined in the config file.
Future improvements:
- Replace axios
- Create log levels
- Improve tests (stryker)
0.0.1
4 years ago