[Fiber] Fix TestUtils.findAllInRenderedTree#8147
Conversation
|
I'm not sure if we should use feature flag in such cases or not. It seems to me that we want "utilities" around React like TestUtils to work with both reconcilers so it's easier to use Fiber side by side. |
| var publicInst = fiber.stateNode; | ||
| var ret = publicInst && test(publicInst) ? [publicInst] : []; | ||
| var child = fiber.child; | ||
| while (child) { |
There was a problem hiding this comment.
Can you add that comment about coroutines that input everywhere? Just so I can find it later. Coroutines have children on stateNode atm.
There was a problem hiding this comment.
I added it at first but then removed because wasn't sure :P. Do couroutines appear in a fully flushed tree? I still don't quite understand how they work.
|
I figured that we'd probably get to feature parity pretty soonish and at that point we could drop the stack one. Presumably we'd cover enough cases there. Unit tests are easy to get a lot of coverage on so less likely to need two impl in parallel for as long. |
* [Fiber] Fix TestUtils.findAllInRenderedTree * Add a comment about coroutines
This fixes a couple of tests (but maybe more in product code).