In this article, Danny Adams showcases how to write some basic feature tests for a HarperDB custom functions (applications) project to ensure that the api routes are working as planned, using Node-tap. We will also write a unit test to ensure that one of our individual functions is working correctly.
- Installing HarperDB locally
- Creating a HarperDB custom functions project
- Setting up HarperDB Studio
- Creating our Schema and Table in HarperDB Studio
- Defining some useful constants for our project
- Creating our HarperDB Custom Function API routes
- Setting up our project for testing
- Testing creating a post
- Testing getting posts
- Things we could improve on in this project