3 ms·
Honestly, the biggest blocker to us having a 'blessed' story around testing isn't figuring out how to test (which is relatively straightforward), it's figuring
by rich_harris 7y ago
Honestly, the biggest blocker to us having a 'blessed' story around testing isn't figuring out how to test (which is relatively straightforward), it's figuring out what to test. Do you really need to test that `<p>Hello {name}!</p>` results in `<p>Hello world!</p>` if `name = world`? Because then you're really just testing that the framework itself isn't buggy, rather than anything to do with your app.
Which isn't to dismiss the concern — just to offer an explanation as to why it hasn't been our top priority so far.
- gedy 7y ago> "Because then you're really just testing that the framework itself isn't buggy" Not in all cases, I maintain some component libraries (mostly React, but a Svelte one too) and ensuring a standard component interface is pretty valuable imho. Enzyme as an example lets you test React components, props, state, etc in isolation but is not very prescriptive about what you 'should' test.