Mocking Node.js with Sinon
By Nate Taylor
Course info



Course info



Description
Creating unit tests that are independent of external systems can be difficult and intimidating. In this course, Mocking Node.js with Sinon, you’ll learn to use the Sinon library for mocking external dependencies while testing your code. First, you’ll explore why mocking matters. Next, you’ll discover the differences between mocks, stubs, spies, and fakes. Finally, you’ll learn how to use a mock in your unit tests. When you’re finished with this course, you’ll have the skills and knowledge of using mocks needed to write unit tests isolated from external dependencies.
Section Introduction Transcripts
Course Overview
[Autogenerated] Hi, everyone. My name is Nate Taylor and welcome to my course, mocking Node.js with signing I am a solution architect at Amateur in Omaha, Nebraska. Creating unit tests is a skill just like any other part of software development. And creating unit tests that are independent of external systems can be tricky and intimidating. To solve that in this course, we're going to cover spying on functions to see what they're doing, stubbing out functions to control how they behave and mocking functions to verify the behavior is correct. By the end of this course, you'll note how and just as importantly, win to create spies. Stubbs fakes and mocks for your unit tests and Node.js before beginning the course. You should be familiar with Node.js and have a basic understanding of what a unit test is. I hope you'll join me on this journey to learn signing Js with the mocking Node.js with signing course at Pluralsight