YGPersistentNodeCloningTest #1813

Closed
NickGerleman wants to merge 1 commits from export-D75572762 into main

1 Commits

Author SHA1 Message Date
Nick Gerleman
6c07329131 YGPersistentNodeCloningTest (#1813)
Summary:

This adds a unit test to Yoga, which emulates the model of "persistent Yoga nodes" and cloning used by React Fabric, including the private (but relied on) Yoga APIs.

It models the over-invalidation exposed in D75287261, which reproduces (due to Yoga incorrectly measuring flex-basis under fit-content, and that constraint changing when sibling changes) but this test for now sets a definite height on A, to show that we only clone what is neccesary, when measure constraints do not have to change.

Having a minimal version of Fabric's model in Yoga unit tests should make some of these interesting interactions a bit easier to debug.

Changelog: [Internal]

Reviewed By: javache

Differential Revision: D75572762
2025-06-02 19:02:19 -07:00