Files
Christoph Purrer 21f08892b8 Drop RCT_EXPORT_METHOD from RCTTestModule TurboModule (#58095)
Summary:
Pull Request resolved: https://github.com/react/react-native/pull/58095

`RCTTestModule` is a TurboModule: it conforms to `NativeTestModuleSpec` and returns
`NativeTestModuleSpecJSI` from `getTurboModule:`, so JS->ObjC dispatch is driven by
codegen, not by `RCT_EXPORT_METHOD`'s `__rct_export__` metadata. The macro is dead weight.
Convert the three spec-declared methods to plain ObjC declarations; conformance to
`NativeTestModuleSpec` keeps their signatures compiler-enforced.

```
- (void)markTestCompleted;
- (void)markTestPassed:(BOOL)success;
- (void)verifySnapshot:(RCTResponseSenderBlock)callback;
```

`sendAppEvent:body:` keeps its macro because it is not declared in the spec protocol, and
the two `RCT_REMAP_METHOD` exports keep theirs because they define custom JS names.

Changelog: [Internal]

Reviewed By: cipolleschi

Differential Revision: D117201272

fbshipit-source-id: 38101da690d8267f8ac4291f9bfc14ab75fd45d3
2026-08-25 08:14:34 -07:00
..