Commit 75f9cad
test(example): make the view harness exercise the RN >= 0.86 props path
The base-view-prop tests could not fail on the pinned RN 0.85.3: `Props::Props`
still filled `Props::rawProps` there, so the missing `initializeDynamicProps`
call in `ViewComponentDescriptor::cloneProps` had no visible effect.
Turning on `enableExclusivePropsUpdateAndroid` makes 0.85 take the same path
0.86+ takes unconditionally, which is what the tests are meant to cover. It can
be dropped once the floor is >= 0.86.
Also fixes the opacity assertion: it asserted on PNG alpha, which is always 255
in a screen capture. It now asserts the blue surface washes out at 10% alpha.
Measured on an API 36 emulator, full `nitro.views.harness`:
without the cloneProps fix: 8 failed, 2 passed
with it: 10 passed
The 11 ArrayBuffer/HardwareBuffer failures in `nitro.harness` are pre-existing
on this emulator and identical with and without the flag.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>1 parent 89e0d2e commit 75f9cad
2 files changed
Lines changed: 42 additions & 0 deletions
File tree
- apps/example
- __tests__
- android/app/src/main/java/com/nitroexample
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
506 | 506 | | |
507 | 507 | | |
508 | 508 | | |
| 509 | + | |
| 510 | + | |
| 511 | + | |
| 512 | + | |
| 513 | + | |
| 514 | + | |
| 515 | + | |
| 516 | + | |
| 517 | + | |
| 518 | + | |
| 519 | + | |
| 520 | + | |
| 521 | + | |
| 522 | + | |
| 523 | + | |
| 524 | + | |
| 525 | + | |
| 526 | + | |
| 527 | + | |
| 528 | + | |
| 529 | + | |
| 530 | + | |
| 531 | + | |
| 532 | + | |
| 533 | + | |
| 534 | + | |
| 535 | + | |
| 536 | + | |
| 537 | + | |
| 538 | + | |
| 539 | + | |
| 540 | + | |
| 541 | + | |
| 542 | + | |
| 543 | + | |
| 544 | + | |
| 545 | + | |
| 546 | + | |
| 547 | + | |
509 | 548 | | |
510 | 549 | | |
511 | 550 | | |
| |||
Lines changed: 3 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
14 | 14 | | |
15 | 15 | | |
16 | 16 | | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
17 | 20 | | |
18 | 21 | | |
19 | 22 | | |
| |||
0 commit comments