Write API Tests with Postman and Newman
- Postman is a good tool which we mostly use to quickly test APIs to see the result returned by them, but it's actually way more powerful than that.
- Making API is hard but Postman makes it simpler,easier.
- You can simply test any API and see the response immediately.
- You can create a collection of API endpoints and call them whenever you want to see the responses.
- We Write Tests in Postman, then export the collection and use Newman to run them directly from the command-line.
npm i newman -g
newman run Collection_fileName.json -e Enviornment_fileName.json