DEV Community

Discussion on: Enzyme is dead. Now what?

stretch0 profile image
Andrew McCallum

RTL is by no means an Enzyme drop-in replacement, so having a completely fresh mindset will help you getting the most of it.

You make a good point. RTL is more of an integration testing library where as Enzyme has the ability to unit test components. This move from unit to integration test focus is a pretty big change for some applications.

marabesi profile image

Even though I see how the thinking behind integration x unit test is, I would recommend to watch Mario's talk on fragile tests (

The mindset of unit x integration around RTL is something that comes up often, and, it's possible to test a single component with RTL as well. The point is, this is not the philosophy of the library (

In this sense, what I understand is: unit does not mean 1-1 (one test one component) rather, one behavior that you want to test.