Transcript

Kent C. Dodds: 0:00 It's time to ditch this boilerplate and jump into React Testing Library. React Testing Library was created by me. Yours truly, Kent C. Dodds. I created it because I really liked the way that we wrote this test where it's all implementation detail-free and it's focused on the users that are actually using our component, but I didn't like the boilerplate.

0:21 That is where React Testing Library came from. In addition to getting rid of this boilerplate, we also add some ability to query things in the way that the user looks around for things on our page as well, which we'll get into later.

0:36 For this first bit, we're mostly just getting rid of some boilerplate. Feel free to read through the background and take a look at this example of how you use React Testing Library.

0:46 Then you can get into the exercise, which basically is just refactoring this to use React Testing Library. Then we've got an extra credit for using jest-dom from the React Testing Library family of tools as well.

1:00 I'll look forward to that, and I'll see you on the other side of the exercise.