opentui
opentui copied to clipboard
test: Add comprehensive React test suite with SolidJS feature parity
Summary
Adds comprehensive test coverage to React reconciler with feature parity to SolidJS tests. 6 logical commits covering testing utilities, rendering, control flow, layout, events, and CJK grapheme rendering analysis. (effectively supersedes #256 albeit different)
Test Results
29 pass ✅
91 skip ⊘ (pre-existing CJK grapheme bugs or unimplemented React components)
0 fail ✅
Coverage
- Basic text & multiline rendering
- Conditional rendering (&&, ternary)
- List rendering with .map()
- Flexbox layout (row/column, flex-grow)
- Dimensions (width, height, padding, margin)
- Positioning (absolute, overflow)
- Alignment (justify-content, align-items)
- Mouse events (onMouseEnter, onMouseLeave)
- Select component events
Commits
- React testing utilities (testRender, captureCharFrame)
- Basic text rendering tests (2 pass)
- Control flow tests (9 pass)
- Layout & styling tests (11 pass)
- Event handling tests (3 pass)
- Textarea and CJK grapheme tests (4 pass, 91 skip)
Update:
- #309 might supersede this PR
@zenyr yes, this one was testing the CJK issue workaround, which is hopefully fixed. @msmps maintains react and he has plans for it.