Sebastian "Sebbie" Silbermann
Sebastian "Sebbie" Silbermann
Thanks for the detailed explanation. Could you clarify how understanding `interval` and `timeout` helped you fix the flakyness? And please clarify what "flaky results" specifically means (fails with what error(s)?).
> the assertion above would fail sometimes and pass sometimes with no change to the code under test. I understand what flaky means. The question is what specific error(s) you...
`createEvent` is a convenience wrapper around how you'd create native events. It looks like you're trying to stub the created event which you wouldn't be able to do in a...
I personally don't like the `import` in the middle of the file. I would recommend importing from `/pure` instead, importing `cleanup` and calling that manually where you think is appropriate.
Probably another instance of #589. @mpeyper does `/react-hooks` manually flush the microtask queue when you're detecting fake timers? It looks like `/react-hooks` doesn't. For comparison, `/react` [manually flushes the microtask...
Yeah makes sense. I had some ideas for a simpler `waitFor` implementation in `/dom` (which `/react`) is using. I'll try to revisit them since that might enable us to use...
It's expected that it doesn't work in the normal configuration because we render into the global `document`. But since now two tests are rendering concurrently into the same document, the...
We currently don't support testing production builds of React. > said to disable it the same way as cleanup. You can also import from `/pure` instead which we currently don't...
> But I think that ideally testing-library should work in browsers, not just inside jest or when using webpack. These are two different things. The library can absolutely be used...
> I guess my point was that [https://github.com/testing-library/react-testing-library/blob/main/dont-cleanup-after-each.js](https://github.com/testing-library/react-testing-library/blob/main/dont-cleanup-after-each.js?rgh-link-date=2022-07-28T18%3A18%3A58Z) cannot run in a browser, and this check is also broken in the browser: You don't need it in a browser. `/pure`...