Commit Graph

5 Commits

Author SHA1 Message Date
Ramanpreet Nara de1fb8f7fd Sort object properties in interop test
Summary:
It looks like objects properties aren't guaranteed to have a stable order. Sort them, before we serializae and print them to the screen in the interop test. This should reduce interop test flakyness.

Changelog: [Internal]

Reviewed By: makovkastar

Differential Revision: D50148860

fbshipit-source-id: a6ed1433d4dd35cafa5c9f7d09c4cca194c31d81
2023-10-11 19:03:01 -07:00
Ramanpreet Nara 271ce7edbc Fix and re-introduce interop test (#39690)
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/39690

This diff re-introduces the test for the TurboModule interop layer.

This test was originally reverted in D49200360, because it was broken.

***New:*** This test runs in Bridgeless mode, with the interop layer enabled. (Catalyst is now native mobileconfig ready).

Changelog: [Internal]

Reviewed By: makovkastar

Differential Revision: D49208528

fbshipit-source-id: 3109d7826e7024fd7a1074321d4aab8f3a489609
2023-09-27 10:18:50 -07:00
Ramanpreet Nara 145659241a Introduce SampleLegacyModule example in RNTester (#38539)
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/38539

We will use this example to:
- Showcase legacy module support in the TurboModule system in RNTester
- E2E test legacy module support in the TurboModule system

Changelog: [Internal]

Reviewed By: NickGerleman

Differential Revision: D47529295

fbshipit-source-id: b98e315741bed7740c36997d706f48e375b0c815
2023-08-21 17:58:46 -07:00
Ramanpreet Nara 99e332e5b2 Introduce jest-e2e test for TurboModule Interop (#38206)
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/38206

This test will ensure that the TurboModule interop layer works in Catalyst.

It will navigate to the sample legacy module screen, and ensure that all methods work.

Steps:
1. Open up Catalyst
2. Navigate to the Legacy Native Module example
3. Click "Run all tests"
4. Validate that all tests match expectations.

Changelog: [Internal]

Reviewed By: NickGerleman

Differential Revision: D46917689

fbshipit-source-id: 071f9324fa3719648c1a390bde4ba00a4e687e44
2023-07-11 11:42:43 -07:00
Ramanpreet Nara a1b64b7f15 Introduce SampleLegacyModule example in RNTester (#38008)
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/38008

Introduce a legacy module (+ example) in RNTester.

In the future, SampleLegacyModule will be used to:
- Showcase the TurboModule interop layer in RNTester, once Bridgeless mode is ready
- E2E Test the TurboModule interop layer.

The TurboModule interop layer is just an extension to the TurboModule system that allows the system to create legacy modules. Unlike regular TurboModules, these legacy modules don't need codegen for JavaScript -> native method dispatch.

Changelog: [Internal]

Reviewed By: cipolleschi

Differential Revision: D46874160

fbshipit-source-id: f9810d0bdb3bd0c0a74099fcb6f74ca547977a53
2023-06-21 18:30:09 -07:00