In this video we'll walk through the TDD thought process using a Fastify healthcheck API along with Jest tests as an example. The process is simple:
Want to see what all the buzz is about with Test Driven Development(TDD)? Look no further! In this video we'll walk through the TDD thought process using a Fastify healthcheck API along with Jest tests as an example. The process is simple: 1. Think about what your new feature needs to do in the code. 2. Write a test that "expects" your app to do that. 3. Run the test in "watch mode". 4. Write code until your test passes! Github Repo with working example: https://github.com/wolfejw86/blog-exa...
Have you stood up a Fastify API with the fastify-cli only to find that it leaves you without your tests setup with your favorite test framework? (jest of course!). Worry no more! In this video I'll show you how to quickly bootstrap a Fastify TypeScript API complete with 100% test coverage using jest!
I use Jest nearly every day when working, and it's a fantastic tool. It lets me ship my code with confidence, knowing that I have produced something which works as intended.
In this video we take a look at a crash course of Fastify as another web / API framework for NodeJS. We discuss how it is similar or differs from something like ExpressJS. We create a new application from scratch using typescript and the fastify CLI. We also take a look at how JSON Schema factors into the application and how to make that work well with TypeScript.