Syed Faraaz Ahmad
Posted on March 13, 2020
I have a basic REST API in a server file. If I want to run tests on the routes, how do I do so?
I can think of 2 ways to do so:
In the test command, first start the server using a child process and then send requests to
localhost
in the unit tests.Write unit tests for all the functions I've written in my code and run them without running the server (Does this mean I can't do integration testing?)
I'm really not sure what to do, I need help.
💖 💪 🙅 🚩
Syed Faraaz Ahmad
Posted on March 13, 2020
Join Our Newsletter. No Spam, Only the good stuff.
Sign up to receive the latest update from our blog.