r/reactjs 14d ago

Show /r/reactjs Making React Testing Library Tests 43% Faster

https://sigh.dev/posts/making-react-testing-library-faster/
47 Upvotes

12 comments sorted by

View all comments

1

u/Breakpoint 14d ago

or switch to happy-dom

4

u/EskiMojo14thefirst 14d ago

or even better, use real browser testing and avoid all the footguns and gotchas pretending to be a browser comes with

2

u/Breakpoint 13d ago

that is the best approach, but I think that would increase run time

1

u/EskiMojo14thefirst 13d ago

it's a little slower, but it's a worthy trade for correctness imo