Unit Testing JavaScript with Jest ✅

preview_player
Показать описание
In this video I will explore unit testing and do a demo unit testing suite to test a sample JavaScript library of functions. I will use Jest - the most popular testing library for JavaScript. The Jest demo will show how to install and setup Jest in your npm project, how to test functions that return integers, floating point numbers, booleans and strings. I'll also cover how to test async functions that fetch data from an API. Finally, I'll explore the concept of Test-Driven Development (TDD) and demonstrate how to implement a simple function using the TDD paradigm.

Content:
0:00 What are Unit Tests?
0:29 Unit Test Example
1:40 Why are Unit Tests Necessary?
2:39 What is Jest?
3:26 Setup Testing with Jest
5:43 Writing Unit Tests
20:48 Writing Tests for Asynchronous Functions
26:17 Test-Driven Development
27:36 Test-Driven Development Demo

Social Media:

#software #testing #js #jest
Рекомендации по теме
Комментарии
Автор

Thanks Nikola for this video, what would you recommend for fronted testing?

zoki
Автор

Not to discourage but it would be nice if your videos were a bit more lively.
Nice tutorial though!!!

isaacoyeniyi
join shbcf.ru