Post API Testing W/Node
- Install Node.js
- Add your project's tests.json file to the same folder as main.js
- Open terminal or cmd on the project's folder
- Run node main.js
The main.js file will run the tests and print the results in the console.
##tests.json format
{
"url":"127.0.0.1",
"name":"APITesting",
"port":8888,
"testgroups":
[
{
"groupname":"User API",
"tests":
[
{
"name":"User Register",
"uri":"user/register",
"input":
{
"username":"test",
"password":"x"
},
"output":
{
"responseStatus":"OK"
}
}
]
}
]
}