mirror of
https://github.com/zhigang1992/react-native.git
synced 2026-04-24 04:16:00 +08:00
[ReactNative] Make JavaScript executors bridge modules
Summary: @public This is the first of a few diffs that change the way the executors are handled by the bridge. For they are just promoted to modules, so they are automatically loaded by the bridge. Test Plan: Tested on UIExplorer, Catalyst and MAdMan. Tested all the 3 executors, everything looks fine.
This commit is contained in:
@@ -133,8 +133,8 @@ RCT_EXPORT_MODULE();
|
||||
(void)bridge;
|
||||
}
|
||||
|
||||
// Sleep on the main thread so the deallocation can happen on the JS thread.
|
||||
sleep(DEFAULT_TIMEOUT);
|
||||
RUN_RUNLOOP_WHILE(weakExecutor, 1);
|
||||
sleep(1);
|
||||
XCTAssertNil(weakExecutor, @"JavaScriptExecutor should have been released");
|
||||
}
|
||||
|
||||
@@ -151,7 +151,8 @@ RCT_EXPORT_MODULE();
|
||||
(void)bridge;
|
||||
}
|
||||
|
||||
sleep(DEFAULT_TIMEOUT);
|
||||
RUN_RUNLOOP_WHILE(weakContext, 1);
|
||||
sleep(1);
|
||||
XCTAssertNil(weakContext, @"RCTJavaScriptContext should have been deallocated");
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user