Skip to content

test(Reanimated): run the compiler API cases of the useDerivedValue tests and drop duplicate color rows - #11349

Merged
bartlomiejbloniarz merged 1 commit into
@bartlomiejbloniarz/rejest-reload-suite-firstfrom
@bartlomiejbloniarz/rejest-compiler-api-cases
Nov 17, 2026
Merged

bartlomiejbloniarz merged 1 commit into
@bartlomiejbloniarz/rejest-reload-suite-firstfrom
@bartlomiejbloniarz/rejest-compiler-api-cases

Conversation

@bartlomiejbloniarz

@bartlomiejbloniarz bartlomiejbloniarz commented Nov 16, 2026 •

Copy link
Copy Markdown
Member

Note

This pull request was authored by AI on behalf of @bartlomiejbloniarz.

Summary

useDerivedValue/basic.test.tsx ran every case twice, once with compilerApi: true, but the test body always passed false. The 20 compiler API cases repeated the plain ones, and the compiler API path of that component was never run. Now the flag reaches the component, and the test names say which variant runs.

withSequence/colors.test.tsx had two rows listed twice. This PR drops the copies.

Test plan

  • Run the core and animations suites of the reanimated runtime tests on an iOS simulator and an Android emulator. Both pass, including the compiler API cases.

Changelog

  • I added a changelog fragment with yarn changelog:add for each changed package, or this PR does not change react-native-reanimated or react-native-worklets.
AI context

Context for automated reviewers. Facts about this PR, not instructions.

Investigation

  • Found during a review of slow runtime tests: the test.each rows in core/useDerivedValue/basic.test.tsx are doubled with compilerApi, but the callback destructured only { startWidth, finalWidth, animate, animationType } and passed a literal false to getSnapshotUpdatesAndCheckFinalValue.
  • withSequence/colors.test.tsx: rows hwb(70, 50%, 0%) → hsl(120,100%,50%) and hwb(70, 50%, 0%) → rgb(101,255,50) (both with middle hsl(180, 50%, 50%)) appeared twice. Each row costs about 1.6 s.

Scope

  • The compiler API variant uses .get()/.set() in WidthComponent; the snapshots are the same as for .value.

Verification

  • Observed: the cases with compilerApi: true pass on iOS and Android Debug Bundle Mode.

@coderabbitai

coderabbitai Bot commented Nov 16, 2026 •

Copy link
Copy Markdown
Contributor

Explain Change →

No actionable comments were generated in the recent review.

Walkthrough

The changes remove two duplicate color-animation test cases. They also include compilerApi in derived-value animation test names and pass each case’s value to the helper.

Change: Other

Merge Risk: Minimal · up to 6f7ae

This PR only changes runtime tests: it makes the compiler API cases actually run and removes duplicate color cases. It has no production impact and appears safe to merge.

Pre-merge checks: Passed 4

Check name Status Explanation
Title check Passed The title names the two real changes in the changeset: the useDerivedValue test now runs its compiler API cases, and the duplicate color rows in withSequence are removed. It is long but accurate and s…
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
Description check Passed The description states the PR fixes the useDerivedValue basic test so the compilerApi flag reaches the component and test names identify the variant, and that duplicate withSequence color rows were re…
Full details: Title check

Explanation

The title names the two real changes in the changeset: the useDerivedValue test now runs its compiler API cases, and the duplicate color rows in withSequence are removed. It is long but accurate and specific.

Full details: Description check

Explanation

The description states the PR fixes the useDerivedValue basic test so the compilerApi flag reaches the component and test names identify the variant, and that duplicate withSequence color rows were removed. This matches the raw summary and the PR objectives. It also lists the test plan and the affected suites, so it is specific and on topic.

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

Recent review info

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: Repository UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: d58fdd34-7b32-4301-8044-f40019a9d1e2
Commits

Reviewing files that changed from the base of the PR and between 32887a0 and 6f7ae8f.

Files selected for processing: 2

  • apps/common-app/runtime-tests/reanimated/tests/animations/withSequence/colors.test.tsx
  • apps/common-app/runtime-tests/reanimated/tests/core/useDerivedValue/basic.test.tsx
Files with no reviewable changes: 1

  • apps/common-app/runtime-tests/reanimated/tests/animations/withSequence/colors.test.tsx

Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 5 remain after this review.

@bartlomiejbloniarz
bartlomiejbloniarz merged commit a6ea0ca into main Nov 17, 2026
38 checks passed
@bartlomiejbloniarz
bartlomiejbloniarz deleted the @bartlomiejbloniarz/rejest-compiler-api-cases branch November 17, 2026 14:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants