Fix RNTesterUnitTests build by importing react/bridging/ArrayBuffer.h#57518
Open
ramonclaudio wants to merge 1 commit into
Open
Fix RNTesterUnitTests build by importing react/bridging/ArrayBuffer.h#57518ramonclaudio wants to merge 1 commit into
ramonclaudio wants to merge 1 commit into
Conversation
RCTTurboModuleArrayBufferTests.mm uses detail::OwnedBytesBuffer, which lives in facebook::react::detail in react/bridging/ArrayBuffer.h, but never imports that header. In the OSS pods build (yarn test-ios / scripts/objc-test.sh) nothing pulls it in transitively, so detail resolves to facebook::jsi::detail and RNTesterUnitTests fails to compile before running a single test. The file already has "using namespace facebook::react", so the import is the whole fix.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary:
Imports
react/bridging/ArrayBuffer.hinRCTTurboModuleArrayBufferTests.mm, soRNTesterUnitTestscompiles andyarn test-iosworks on main again.The test uses
detail::OwnedBytesBuffer, which lives infacebook::react::detailin that header, but never imports it, and nothing in its include chain provides it, sodetailresolves tofacebook::jsi::detailand the target fails to compile before running a single test. The file already hasusing namespace facebook::react;, so the import is the entire fix. CI stays green because thetest_ios_rntesterjobs only build the app scheme and never compileRNTesterUnitTests, which means this file has never compiled in the repo since it landed in 54b88d9, and theyarn test-iosflow the contributing docs point at is the only thing that compiles it.Changelog:
[INTERNAL] [FIXED] - Fix RNTesterUnitTests build by importing react/bridging/ArrayBuffer.h in RCTTurboModuleArrayBufferTests
Test Plan:
xcodebuild build-for-testing -workspace RNTesterPods.xcworkspace -scheme RNTester -sdk iphonesimulatorfails with the errors above, zero tests run. With it, the same build succeeds with no errors in the file.clang-format --dry-run --Werror.