Browse Source

Support RN 0.59 (#5050)

* Support RN 0.59

* Fix yellow box detection on Android
* Manually link jsc on iOS in playground app

* Fix android unit tests

* Add JavaScriptCore.framework to iOS unit tests

* Download licenses before unit and e2e tests

* Update gradle-wrapper.properties
Guy Carmeli 5 years ago
parent
commit
d00bf22a1d

+ 7
- 10
babel.config.js View File

@@ -1,15 +1,12 @@
1 1
 module.exports = function (api) {
2 2
   api && api.cache(false);
3 3
   return {
4
-    env: {
5
-      test: {
6
-        presets: [
7
-          "module:metro-react-native-babel-preset"
8
-        ],
9
-        plugins: [
10
-          "@babel/plugin-proposal-class-properties"
11
-        ]
12
-      }
13
-    }
4
+    presets: [
5
+      "module:metro-react-native-babel-preset"
6
+    ],
7
+    plugins: [
8
+      "@babel/plugin-proposal-export-namespace-from",
9
+      "@babel/plugin-proposal-export-default-from"
10
+    ]
14 11
   };
15 12
 }

+ 3
- 3
lib/android/app/build.gradle View File

@@ -5,10 +5,10 @@ def safeExtGet(prop, fallback) {
5 5
     rootProject.ext.has(prop) ? rootProject.ext.get(prop) : fallback
6 6
 }
7 7
 
8
-def DEFAULT_COMPILE_SDK_VERSION = 26
8
+def DEFAULT_COMPILE_SDK_VERSION = 28
9 9
 def DEFAULT_MIN_SDK_VERSION = 19
10
-def DEFAULT_SUPPORT_LIB_VERSION = '26.1.0'
11
-def DEFAULT_TARGET_SDK_VERSION = 25
10
+def DEFAULT_SUPPORT_LIB_VERSION = '28.0.0'
11
+def DEFAULT_TARGET_SDK_VERSION = 28
12 12
 
13 13
 android {
14 14
     compileSdkVersion safeExtGet('compileSdkVersion', DEFAULT_COMPILE_SDK_VERSION)

+ 3
- 15
lib/android/app/src/main/java/com/reactnativenavigation/viewcontrollers/YellowBoxHelper.java View File

@@ -1,24 +1,12 @@
1 1
 package com.reactnativenavigation.viewcontrollers;
2 2
 
3
-import android.support.annotation.NonNull;
4 3
 import android.view.View;
5 4
 import android.view.ViewGroup;
6 5
 
7
-import com.facebook.react.views.view.ReactViewBackgroundDrawable;
8
-import com.reactnativenavigation.utils.ViewUtils;
9
-
10
-public class YellowBoxHelper {
11
-    private final static int YELLOW_BOX_COLOR = -218449360;
12
-
13
-    public boolean isYellowBox(View parent, View child) {
6
+class YellowBoxHelper {
7
+    boolean isYellowBox(View parent, View child) {
14 8
         return parent instanceof ViewGroup &&
15 9
                child instanceof ViewGroup &&
16
-               ((ViewGroup) parent).getChildCount() > 1 &&
17
-               !ViewUtils.findChildrenByClassRecursive((ViewGroup) child, View.class, YellowBackgroundMather()).isEmpty();
18
-    }
19
-
20
-    @NonNull
21
-    private static ViewUtils.Matcher<View> YellowBackgroundMather() {
22
-        return child1 -> child1.getBackground() instanceof ReactViewBackgroundDrawable && ((ReactViewBackgroundDrawable) child1.getBackground()).getColor() == YELLOW_BOX_COLOR;
10
+               ((ViewGroup) parent).getChildCount() > 1;
23 11
     }
24 12
 }

+ 0
- 50
lib/android/app/src/test/java/com/reactnativenavigation/mocks/MockPromise.java View File

@@ -1,50 +0,0 @@
1
-package com.reactnativenavigation.mocks;
2
-
3
-import com.facebook.react.bridge.*;
4
-
5
-import javax.annotation.*;
6
-
7
-
8
-public class MockPromise implements Promise {
9
-    private boolean invoked;
10
-
11
-    @Override
12
-    public void resolve(@Nullable Object value) {
13
-        throwIfInvoked();
14
-        invoked = true;
15
-    }
16
-
17
-    @Override
18
-    public void reject(String code, String message) {
19
-        throwIfInvoked();
20
-        invoked = true;
21
-    }
22
-
23
-    @Override
24
-    public void reject(String code, Throwable e) {
25
-        throwIfInvoked();
26
-        invoked = true;
27
-    }
28
-
29
-    @Override
30
-    public void reject(String code, String message, Throwable e) {
31
-        throwIfInvoked();
32
-        invoked = true;
33
-    }
34
-
35
-    @Override
36
-    public void reject(String message) {
37
-        throwIfInvoked();
38
-        invoked = true;
39
-    }
40
-
41
-    @Override
42
-    public void reject(Throwable reason) {
43
-        throwIfInvoked();
44
-        invoked = true;
45
-    }
46
-
47
-    private void throwIfInvoked() {
48
-        if (invoked) throw new RuntimeException("Promise can be resolved or rejected only once");
49
-    }
50
-}

+ 14
- 17
lib/android/app/src/test/java/com/reactnativenavigation/utils/TypefaceLoaderTest.java View File

@@ -2,7 +2,6 @@ package com.reactnativenavigation.utils;
2 2
 
3 3
 import android.content.*;
4 4
 import android.graphics.*;
5
-import android.test.mock.*;
6 5
 
7 6
 import com.reactnativenavigation.*;
8 7
 
@@ -12,47 +11,45 @@ import org.mockito.*;
12 11
 import static org.assertj.core.api.Java6Assertions.*;
13 12
 
14 13
 public class TypefaceLoaderTest extends BaseTest {
14
+    private TypefaceLoader uut;
15
+    @Override
16
+    public void beforeEach() {
17
+        Context context = Mockito.mock(Context.class);
18
+        uut = Mockito.spy(new TypefaceLoader(context));
19
+    }
15 20
 
16 21
     @Test
17 22
     public void loadTypefaceNoAssets() {
18
-        Context context = new MockContext();
19
-        TypefaceLoader mockedLoader = Mockito.spy(new TypefaceLoader(context));
20
-        Mockito.doReturn(null).when(mockedLoader).getTypefaceFromAssets("Helvetica-Bold");
23
+        Mockito.doReturn(null).when(uut).getTypefaceFromAssets("Helvetica-Bold");
21 24
 
22
-        Typeface typeface = mockedLoader.getTypeFace("Helvetica-Bold");
25
+        Typeface typeface = uut.getTypeFace("Helvetica-Bold");
23 26
         assertThat(typeface).isNotNull();
24 27
         assertThat(typeface.getStyle()).isEqualTo(Typeface.BOLD);
25 28
     }
26 29
 
27 30
     @Test
28 31
     public void loadTypefaceWithAssets() {
29
-        Context context = new MockContext();
30
-        TypefaceLoader mockedLoader = Mockito.spy(new TypefaceLoader(context));
31
-        Mockito.doReturn(Typeface.create("Helvetica-Italic", Typeface.ITALIC)).when(mockedLoader).getTypefaceFromAssets("Helvetica-Italic");
32
+        Mockito.doReturn(Typeface.create("Helvetica-Italic", Typeface.ITALIC)).when(uut).getTypefaceFromAssets("Helvetica-Italic");
32 33
 
33
-        Typeface typeface = mockedLoader.getTypeFace("Helvetica-Italic");
34
+        Typeface typeface = uut.getTypeFace("Helvetica-Italic");
34 35
         assertThat(typeface).isNotNull();
35 36
         assertThat(typeface.getStyle()).isEqualTo(Typeface.ITALIC);
36 37
     }
37 38
 
38 39
     @Test
39 40
     public void loadTypefaceWrongName() {
40
-        Context context = new MockContext();
41
-        TypefaceLoader mockedLoader = Mockito.spy(new TypefaceLoader(context));
42
-        Mockito.doReturn(null).when(mockedLoader).getTypefaceFromAssets("Some-name");
41
+        Mockito.doReturn(null).when(uut).getTypefaceFromAssets("Some-name");
43 42
 
44
-        Typeface typeface = mockedLoader.getTypeFace("Some-name");
43
+        Typeface typeface = uut.getTypeFace("Some-name");
45 44
         assertThat(typeface).isNotNull();
46 45
         assertThat(typeface.getStyle()).isEqualTo(Typeface.NORMAL);
47 46
     }
48 47
 
49 48
     @Test
50 49
     public void loadTypefaceNull() {
51
-        Context context = new MockContext();
52
-        TypefaceLoader mockedLoader = Mockito.spy(new TypefaceLoader(context));
53
-        Mockito.doReturn(null).when(mockedLoader).getTypefaceFromAssets(null);
50
+        Mockito.doReturn(null).when(uut).getTypefaceFromAssets(null);
54 51
 
55
-        Typeface typeface = mockedLoader.getTypeFace(null);
52
+        Typeface typeface = uut.getTypeFace(null);
56 53
         assertThat(typeface).isNull();
57 54
     }
58 55
 }

+ 4
- 2
lib/ios/ReactNativeNavigation.xcodeproj/project.pbxproj View File

@@ -213,6 +213,7 @@
213 213
 		50887C1620ECC5C200D06111 /* RNNButtonOptions.m in Sources */ = {isa = PBXBuildFile; fileRef = 50887C1420ECC5C200D06111 /* RNNButtonOptions.m */; };
214 214
 		50887CA920F26BFE00D06111 /* RNNOverlayWindow.m in Sources */ = {isa = PBXBuildFile; fileRef = 50887CA720F26BFD00D06111 /* RNNOverlayWindow.m */; };
215 215
 		50887CAA20F26BFE00D06111 /* RNNOverlayWindow.h in Headers */ = {isa = PBXBuildFile; fileRef = 50887CA820F26BFE00D06111 /* RNNOverlayWindow.h */; };
216
+		508EBDBD2278746400BEC144 /* JavaScriptCore.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 508EBDBA2278742700BEC144 /* JavaScriptCore.framework */; };
216 217
 		509B2480217873FF00C83C23 /* UINavigationController+RNNOptionsTest.m in Sources */ = {isa = PBXBuildFile; fileRef = 509B247F217873FF00C83C23 /* UINavigationController+RNNOptionsTest.m */; };
217 218
 		509B258F2178BE7A00C83C23 /* RNNNavigationControllerPresenterTest.m in Sources */ = {isa = PBXBuildFile; fileRef = 509B258E2178BE7A00C83C23 /* RNNNavigationControllerPresenterTest.m */; };
218 219
 		50A00C37200F84D6000F01A6 /* RNNOverlayOptions.h in Headers */ = {isa = PBXBuildFile; fileRef = 50A00C35200F84D6000F01A6 /* RNNOverlayOptions.h */; };
@@ -266,7 +267,6 @@
266 267
 		7B49FECE1E95098500DEB3EA /* RNNCommandsHandlerTest.m in Sources */ = {isa = PBXBuildFile; fileRef = 7B49FEC91E95098500DEB3EA /* RNNCommandsHandlerTest.m */; };
267 268
 		7B49FECF1E95098500DEB3EA /* RNNNavigationStackManagerTest.m in Sources */ = {isa = PBXBuildFile; fileRef = 7B49FECA1E95098500DEB3EA /* RNNNavigationStackManagerTest.m */; };
268 269
 		7B49FEDF1E950A7A00DEB3EA /* libcxxreact.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 7B49FED11E950A7A00DEB3EA /* libcxxreact.a */; };
269
-		7B49FEE01E950A7A00DEB3EA /* libjschelpers.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 7B49FED21E950A7A00DEB3EA /* libjschelpers.a */; };
270 270
 		7B49FEE11E950A7A00DEB3EA /* libRCTActionSheet.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 7B49FED31E950A7A00DEB3EA /* libRCTActionSheet.a */; };
271 271
 		7B49FEE21E950A7A00DEB3EA /* libRCTAnimation.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 7B49FED41E950A7A00DEB3EA /* libRCTAnimation.a */; };
272 272
 		7B49FEE31E950A7A00DEB3EA /* libRCTGeolocation.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 7B49FED51E950A7A00DEB3EA /* libRCTGeolocation.a */; };
@@ -554,6 +554,7 @@
554 554
 		50887C1420ECC5C200D06111 /* RNNButtonOptions.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RNNButtonOptions.m; sourceTree = "<group>"; };
555 555
 		50887CA720F26BFD00D06111 /* RNNOverlayWindow.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RNNOverlayWindow.m; sourceTree = "<group>"; };
556 556
 		50887CA820F26BFE00D06111 /* RNNOverlayWindow.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RNNOverlayWindow.h; sourceTree = "<group>"; };
557
+		508EBDBA2278742700BEC144 /* JavaScriptCore.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = JavaScriptCore.framework; path = System/Library/Frameworks/JavaScriptCore.framework; sourceTree = SDKROOT; };
557 558
 		509B247F217873FF00C83C23 /* UINavigationController+RNNOptionsTest.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = "UINavigationController+RNNOptionsTest.m"; sourceTree = "<group>"; };
558 559
 		509B258E2178BE7A00C83C23 /* RNNNavigationControllerPresenterTest.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RNNNavigationControllerPresenterTest.m; sourceTree = "<group>"; };
559 560
 		50A00C35200F84D6000F01A6 /* RNNOverlayOptions.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RNNOverlayOptions.h; sourceTree = "<group>"; };
@@ -680,8 +681,8 @@
680 681
 			isa = PBXFrameworksBuildPhase;
681 682
 			buildActionMask = 2147483647;
682 683
 			files = (
684
+				508EBDBD2278746400BEC144 /* JavaScriptCore.framework in Frameworks */,
683 685
 				7B49FEDF1E950A7A00DEB3EA /* libcxxreact.a in Frameworks */,
684
-				7B49FEE01E950A7A00DEB3EA /* libjschelpers.a in Frameworks */,
685 686
 				7B49FEE11E950A7A00DEB3EA /* libRCTActionSheet.a in Frameworks */,
686 687
 				7B49FEE21E950A7A00DEB3EA /* libRCTAnimation.a in Frameworks */,
687 688
 				7B49FEE31E950A7A00DEB3EA /* libRCTGeolocation.a in Frameworks */,
@@ -1093,6 +1094,7 @@
1093 1094
 		7B49FED01E950A7A00DEB3EA /* Frameworks */ = {
1094 1095
 			isa = PBXGroup;
1095 1096
 			children = (
1097
+				508EBDBA2278742700BEC144 /* JavaScriptCore.framework */,
1096 1098
 				501214C8217741A000435148 /* libOCMock.a */,
1097 1099
 				7B49FED11E950A7A00DEB3EA /* libcxxreact.a */,
1098 1100
 				7B49FED21E950A7A00DEB3EA /* libjschelpers.a */,

+ 10
- 2
metro.config.js View File

@@ -3,8 +3,16 @@ module.exports = {
3 3
   watchFolders: [
4 4
     __dirname
5 5
   ],
6
+  resolver: {
7
+    sourceExts: ['ts', 'tsx', 'js']
8
+  },
6 9
   transformer: {
7
-    babelTransformerPath: require.resolve('react-native-typescript-transformer')
10
+    babelTransformerPath: require.resolve('react-native-typescript-transformer'),
11
+    getTransformOptions: async () => ({
12
+      transform: {
13
+        experimentalImportSupport: false,
14
+        inlineRequires: false,
15
+      },
16
+    })
8 17
   }
9 18
 };
10
-

+ 8
- 6
package.json View File

@@ -53,21 +53,23 @@
53 53
     "tslib": "1.9.3"
54 54
   },
55 55
   "devDependencies": {
56
+    "@babel/plugin-proposal-export-default-from": "7.2.0",
57
+    "@babel/plugin-proposal-export-namespace-from": "7.2.0",
56 58
     "@types/hoist-non-react-statics": "^3.0.1",
57 59
     "@types/jest": "23.x.x",
58 60
     "@types/lodash": "4.x.x",
59 61
     "@types/react": "16.x.x",
60 62
     "@types/react-native": "0.57.7",
61 63
     "@types/react-test-renderer": "16.x.x",
62
-    "jsc-android": "236355.x.x",
63 64
     "detox": "12.x.x",
64 65
     "react-native-ui-lib": "3.24.2",
65 66
     "handlebars": "4.x.x",
66
-    "jest": "23.x.x",
67
-    "metro-react-native-babel-preset": "0.50.0",
68
-    "react": "16.6.1",
69
-    "react-native": "0.57.7",
70
-    "react-native-typescript-transformer": "^1.2.10",
67
+    "jest": "24.0.0-alpha.6",
68
+    "jsc-android": "236355.x.x",
69
+    "metro-react-native-babel-preset": "0.52.x",
70
+    "react": "16.8.3",
71
+    "react-native": "0.59.5",
72
+    "react-native-typescript-transformer": "1.2.12",
71 73
     "react-native-view-overflow": "0.0.3",
72 74
     "react-redux": "5.x.x",
73 75
     "react-test-renderer": "16.6.1",

+ 2
- 2
playground/android/build.gradle View File

@@ -1,7 +1,7 @@
1 1
 // Top-level build file where you can add configuration options common to all sub-projects/modules.
2 2
 
3 3
 buildscript {
4
-    ext.kotlinVersion = '1.3.21'
4
+    ext.kotlinVersion = '1.3.31'
5 5
     ext.detoxKotlinVersion = ext.kotlinVersion
6 6
 
7 7
     repositories {
@@ -11,7 +11,7 @@ buildscript {
11 11
         jcenter()
12 12
     }
13 13
     dependencies {
14
-        classpath 'com.android.tools.build:gradle:3.2.1'
14
+        classpath 'com.android.tools.build:gradle:3.3.1'
15 15
         classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlinVersion"
16 16
 
17 17
         // NOTE: Do not place your application dependencies here; they belong

+ 1
- 1
playground/android/gradle/wrapper/gradle-wrapper.properties View File

@@ -3,4 +3,4 @@ distributionBase=GRADLE_USER_HOME
3 3
 distributionPath=wrapper/dists
4 4
 zipStoreBase=GRADLE_USER_HOME
5 5
 zipStorePath=wrapper/dists
6
-distributionUrl=https\://services.gradle.org/distributions/gradle-4.10-all.zip
6
+distributionUrl=https\://services.gradle.org/distributions/gradle-4.10.1-all.zip

+ 95
- 55
playground/ios/playground.xcodeproj/project.pbxproj View File

@@ -13,7 +13,6 @@
13 13
 		13B07FC11A68108700A75B9A /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 13B07FB71A68108700A75B9A /* main.m */; };
14 14
 		50451D35204451A900695F00 /* RNNCustomViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 50451D34204451A800695F00 /* RNNCustomViewController.m */; };
15 15
 		7B8F30491E84151300110AEC /* libcxxreact.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 7B8F2FDE1E840F3600110AEC /* libcxxreact.a */; };
16
-		7B8F304A1E84151300110AEC /* libjschelpers.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 7B8F2FE21E840F3600110AEC /* libjschelpers.a */; };
17 16
 		7B8F304B1E84151300110AEC /* libRCTActionSheet.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 7B8F2FFA1E8411A800110AEC /* libRCTActionSheet.a */; };
18 17
 		7B8F304C1E84151300110AEC /* libRCTAnimation.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 7B8F2FEB1E840F6700110AEC /* libRCTAnimation.a */; };
19 18
 		7B8F304D1E84151300110AEC /* libRCTGeolocation.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 7B8F300C1E84124A00110AEC /* libRCTGeolocation.a */; };
@@ -27,6 +26,7 @@
27 26
 		7B8F30551E84151300110AEC /* libReact.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 7B8F2FD61E840F3600110AEC /* libReact.a */; };
28 27
 		7B8F30561E84151300110AEC /* libReactNativeNavigation.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 7B8F2FC91E840F1A00110AEC /* libReactNativeNavigation.a */; };
29 28
 		7B8F30571E84151300110AEC /* libyoga.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 7B8F2FDA1E840F3600110AEC /* libyoga.a */; };
29
+		E5046080227748EA00212BD8 /* JavaScriptCore.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = E504607F227748EA00212BD8 /* JavaScriptCore.framework */; };
30 30
 /* End PBXBuildFile section */
31 31
 
32 32
 /* Begin PBXContainerItemProxy section */
@@ -44,13 +44,6 @@
44 44
 			remoteGlobalIDString = 3DBE0D0D1F3B181C0099AA32;
45 45
 			remoteInfo = "fishhook-tvOS";
46 46
 		};
47
-		501223FD2173591A000F5F98 /* PBXContainerItemProxy */ = {
48
-			isa = PBXContainerItemProxy;
49
-			containerPortal = 7B8F2FCA1E840F3600110AEC /* React.xcodeproj */;
50
-			proxyType = 2;
51
-			remoteGlobalIDString = 9936F32F1F5F2E5B0010BF04;
52
-			remoteInfo = "privatedata-tvOS";
53
-		};
54 47
 		7B49FF081E950AF400DEB3EA /* PBXContainerItemProxy */ = {
55 48
 			isa = PBXContainerItemProxy;
56 49
 			containerPortal = 7B8F2FC41E840F1A00110AEC /* ReactNativeNavigation.xcodeproj */;
@@ -107,20 +100,6 @@
107 100
 			remoteGlobalIDString = 3D3CD9321DE5FBEE00167DC4;
108 101
 			remoteInfo = "cxxreact-tvOS";
109 102
 		};
110
-		7B8F2FE11E840F3600110AEC /* PBXContainerItemProxy */ = {
111
-			isa = PBXContainerItemProxy;
112
-			containerPortal = 7B8F2FCA1E840F3600110AEC /* React.xcodeproj */;
113
-			proxyType = 2;
114
-			remoteGlobalIDString = 3D3CD90B1DE5FBD600167DC4;
115
-			remoteInfo = jschelpers;
116
-		};
117
-		7B8F2FE31E840F3600110AEC /* PBXContainerItemProxy */ = {
118
-			isa = PBXContainerItemProxy;
119
-			containerPortal = 7B8F2FCA1E840F3600110AEC /* React.xcodeproj */;
120
-			proxyType = 2;
121
-			remoteGlobalIDString = 3D3CD9181DE5FBD800167DC4;
122
-			remoteInfo = "jschelpers-tvOS";
123
-		};
124 103
 		7B8F2FEA1E840F6700110AEC /* PBXContainerItemProxy */ = {
125 104
 			isa = PBXContainerItemProxy;
126 105
 			containerPortal = 7B8F2FE51E840F6700110AEC /* RCTAnimation.xcodeproj */;
@@ -240,12 +219,47 @@
240 219
 			remoteGlobalIDString = 2D2A28881D9B049200D4039D;
241 220
 			remoteInfo = "RCTWebSocket-tvOS";
242 221
 		};
243
-		E506412420A3138100EC769F /* PBXContainerItemProxy */ = {
222
+		E5046070227748DD00212BD8 /* PBXContainerItemProxy */ = {
244 223
 			isa = PBXContainerItemProxy;
245 224
 			containerPortal = 7B8F2FCA1E840F3600110AEC /* React.xcodeproj */;
246 225
 			proxyType = 2;
247
-			remoteGlobalIDString = 9936F3131F5F2E4B0010BF04;
248
-			remoteInfo = privatedata;
226
+			remoteGlobalIDString = EBF21BDC1FC498900052F4D5;
227
+			remoteInfo = jsinspector;
228
+		};
229
+		E5046072227748DD00212BD8 /* PBXContainerItemProxy */ = {
230
+			isa = PBXContainerItemProxy;
231
+			containerPortal = 7B8F2FCA1E840F3600110AEC /* React.xcodeproj */;
232
+			proxyType = 2;
233
+			remoteGlobalIDString = EBF21BFA1FC4989A0052F4D5;
234
+			remoteInfo = "jsinspector-tvOS";
235
+		};
236
+		E5046074227748DD00212BD8 /* PBXContainerItemProxy */ = {
237
+			isa = PBXContainerItemProxy;
238
+			containerPortal = 7B8F2FCA1E840F3600110AEC /* React.xcodeproj */;
239
+			proxyType = 2;
240
+			remoteGlobalIDString = EDEBC6D6214B3E7000DD5AC8;
241
+			remoteInfo = jsi;
242
+		};
243
+		E5046076227748DD00212BD8 /* PBXContainerItemProxy */ = {
244
+			isa = PBXContainerItemProxy;
245
+			containerPortal = 7B8F2FCA1E840F3600110AEC /* React.xcodeproj */;
246
+			proxyType = 2;
247
+			remoteGlobalIDString = EDEBC73B214B45A300DD5AC8;
248
+			remoteInfo = jsiexecutor;
249
+		};
250
+		E5046078227748DD00212BD8 /* PBXContainerItemProxy */ = {
251
+			isa = PBXContainerItemProxy;
252
+			containerPortal = 7B8F2FCA1E840F3600110AEC /* React.xcodeproj */;
253
+			proxyType = 2;
254
+			remoteGlobalIDString = ED296FB6214C9A0900B7C4FE;
255
+			remoteInfo = "jsi-tvOS";
256
+		};
257
+		E504607A227748DD00212BD8 /* PBXContainerItemProxy */ = {
258
+			isa = PBXContainerItemProxy;
259
+			containerPortal = 7B8F2FCA1E840F3600110AEC /* React.xcodeproj */;
260
+			proxyType = 2;
261
+			remoteGlobalIDString = ED296FEE214C9CF800B7C4FE;
262
+			remoteInfo = "jsiexecutor-tvOS";
249 263
 		};
250 264
 		E8CB6AA71FF10BC4007C82EF /* PBXContainerItemProxy */ = {
251 265
 			isa = PBXContainerItemProxy;
@@ -299,6 +313,7 @@
299 313
 		7B8F30311E8412A600110AEC /* RCTText.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = RCTText.xcodeproj; path = "../../node_modules/react-native/Libraries/Text/RCTText.xcodeproj"; sourceTree = "<group>"; };
300 314
 		7B8F303A1E8412B700110AEC /* RCTVibration.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = RCTVibration.xcodeproj; path = "../../node_modules/react-native/Libraries/Vibration/RCTVibration.xcodeproj"; sourceTree = "<group>"; };
301 315
 		7B8F30401E8412E100110AEC /* RCTWebSocket.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = RCTWebSocket.xcodeproj; path = "../../node_modules/react-native/Libraries/WebSocket/RCTWebSocket.xcodeproj"; sourceTree = "<group>"; };
316
+		E504607F227748EA00212BD8 /* JavaScriptCore.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = JavaScriptCore.framework; path = System/Library/Frameworks/JavaScriptCore.framework; sourceTree = SDKROOT; };
302 317
 /* End PBXFileReference section */
303 318
 
304 319
 /* Begin PBXFrameworksBuildPhase section */
@@ -306,8 +321,8 @@
306 321
 			isa = PBXFrameworksBuildPhase;
307 322
 			buildActionMask = 2147483647;
308 323
 			files = (
324
+				E5046080227748EA00212BD8 /* JavaScriptCore.framework in Frameworks */,
309 325
 				7B8F30491E84151300110AEC /* libcxxreact.a in Frameworks */,
310
-				7B8F304A1E84151300110AEC /* libjschelpers.a in Frameworks */,
311 326
 				7B8F304B1E84151300110AEC /* libRCTActionSheet.a in Frameworks */,
312 327
 				7B8F304C1E84151300110AEC /* libRCTAnimation.a in Frameworks */,
313 328
 				7B8F304D1E84151300110AEC /* libRCTGeolocation.a in Frameworks */,
@@ -360,14 +375,16 @@
360 375
 				7B8F2FDC1E840F3600110AEC /* libyoga.a */,
361 376
 				7B8F2FDE1E840F3600110AEC /* libcxxreact.a */,
362 377
 				7B8F2FE01E840F3600110AEC /* libcxxreact.a */,
363
-				7B8F2FE21E840F3600110AEC /* libjschelpers.a */,
364
-				7B8F2FE41E840F3600110AEC /* libjschelpers.a */,
378
+				E5046071227748DD00212BD8 /* libjsinspector.a */,
379
+				E5046073227748DD00212BD8 /* libjsinspector-tvOS.a */,
365 380
 				E8CB6AA81FF10BC4007C82EF /* libthird-party.a */,
366 381
 				E8CB6AAA1FF10BC4007C82EF /* libthird-party.a */,
367 382
 				E8CB6AAC1FF10BC4007C82EF /* libdouble-conversion.a */,
368 383
 				E8CB6AAE1FF10BC4007C82EF /* libdouble-conversion.a */,
369
-				E506412520A3138100EC769F /* libprivatedata.a */,
370
-				501223FE2173591A000F5F98 /* libprivatedata-tvOS.a */,
384
+				E5046075227748DD00212BD8 /* libjsi.a */,
385
+				E5046077227748DD00212BD8 /* libjsiexecutor.a */,
386
+				E5046079227748DD00212BD8 /* libjsi-tvOS.a */,
387
+				E504607B227748DD00212BD8 /* libjsiexecutor-tvOS.a */,
371 388
 			);
372 389
 			name = Products;
373 390
 			sourceTree = "<group>";
@@ -486,6 +503,7 @@
486 503
 				13B07FAE1A68108700A75B9A /* playground */,
487 504
 				832341AE1AAA6A7D00B99B32 /* Libraries */,
488 505
 				83CBBA001A601CBA00E9B192 /* Products */,
506
+				E504607E227748E900212BD8 /* Frameworks */,
489 507
 			);
490 508
 			indentWidth = 4;
491 509
 			sourceTree = "<group>";
@@ -500,6 +518,14 @@
500 518
 			name = Products;
501 519
 			sourceTree = "<group>";
502 520
 		};
521
+		E504607E227748E900212BD8 /* Frameworks */ = {
522
+			isa = PBXGroup;
523
+			children = (
524
+				E504607F227748EA00212BD8 /* JavaScriptCore.framework */,
525
+			);
526
+			name = Frameworks;
527
+			sourceTree = "<group>";
528
+		};
503 529
 /* End PBXGroup section */
504 530
 
505 531
 /* Begin PBXNativeTarget section */
@@ -618,13 +644,6 @@
618 644
 			remoteRef = 39D599B0200F3D5C00A3B2ED /* PBXContainerItemProxy */;
619 645
 			sourceTree = BUILT_PRODUCTS_DIR;
620 646
 		};
621
-		501223FE2173591A000F5F98 /* libprivatedata-tvOS.a */ = {
622
-			isa = PBXReferenceProxy;
623
-			fileType = archive.ar;
624
-			path = "libprivatedata-tvOS.a";
625
-			remoteRef = 501223FD2173591A000F5F98 /* PBXContainerItemProxy */;
626
-			sourceTree = BUILT_PRODUCTS_DIR;
627
-		};
628 647
 		7B49FF091E950AF400DEB3EA /* ReactNativeNavigationTests.xctest */ = {
629 648
 			isa = PBXReferenceProxy;
630 649
 			fileType = wrapper.cfbundle;
@@ -681,20 +700,6 @@
681 700
 			remoteRef = 7B8F2FDF1E840F3600110AEC /* PBXContainerItemProxy */;
682 701
 			sourceTree = BUILT_PRODUCTS_DIR;
683 702
 		};
684
-		7B8F2FE21E840F3600110AEC /* libjschelpers.a */ = {
685
-			isa = PBXReferenceProxy;
686
-			fileType = archive.ar;
687
-			path = libjschelpers.a;
688
-			remoteRef = 7B8F2FE11E840F3600110AEC /* PBXContainerItemProxy */;
689
-			sourceTree = BUILT_PRODUCTS_DIR;
690
-		};
691
-		7B8F2FE41E840F3600110AEC /* libjschelpers.a */ = {
692
-			isa = PBXReferenceProxy;
693
-			fileType = archive.ar;
694
-			path = libjschelpers.a;
695
-			remoteRef = 7B8F2FE31E840F3600110AEC /* PBXContainerItemProxy */;
696
-			sourceTree = BUILT_PRODUCTS_DIR;
697
-		};
698 703
 		7B8F2FEB1E840F6700110AEC /* libRCTAnimation.a */ = {
699 704
 			isa = PBXReferenceProxy;
700 705
 			fileType = archive.ar;
@@ -814,11 +819,46 @@
814 819
 			remoteRef = 7B8F30471E8412E100110AEC /* PBXContainerItemProxy */;
815 820
 			sourceTree = BUILT_PRODUCTS_DIR;
816 821
 		};
817
-		E506412520A3138100EC769F /* libprivatedata.a */ = {
822
+		E5046071227748DD00212BD8 /* libjsinspector.a */ = {
823
+			isa = PBXReferenceProxy;
824
+			fileType = archive.ar;
825
+			path = libjsinspector.a;
826
+			remoteRef = E5046070227748DD00212BD8 /* PBXContainerItemProxy */;
827
+			sourceTree = BUILT_PRODUCTS_DIR;
828
+		};
829
+		E5046073227748DD00212BD8 /* libjsinspector-tvOS.a */ = {
830
+			isa = PBXReferenceProxy;
831
+			fileType = archive.ar;
832
+			path = "libjsinspector-tvOS.a";
833
+			remoteRef = E5046072227748DD00212BD8 /* PBXContainerItemProxy */;
834
+			sourceTree = BUILT_PRODUCTS_DIR;
835
+		};
836
+		E5046075227748DD00212BD8 /* libjsi.a */ = {
837
+			isa = PBXReferenceProxy;
838
+			fileType = archive.ar;
839
+			path = libjsi.a;
840
+			remoteRef = E5046074227748DD00212BD8 /* PBXContainerItemProxy */;
841
+			sourceTree = BUILT_PRODUCTS_DIR;
842
+		};
843
+		E5046077227748DD00212BD8 /* libjsiexecutor.a */ = {
844
+			isa = PBXReferenceProxy;
845
+			fileType = archive.ar;
846
+			path = libjsiexecutor.a;
847
+			remoteRef = E5046076227748DD00212BD8 /* PBXContainerItemProxy */;
848
+			sourceTree = BUILT_PRODUCTS_DIR;
849
+		};
850
+		E5046079227748DD00212BD8 /* libjsi-tvOS.a */ = {
851
+			isa = PBXReferenceProxy;
852
+			fileType = archive.ar;
853
+			path = "libjsi-tvOS.a";
854
+			remoteRef = E5046078227748DD00212BD8 /* PBXContainerItemProxy */;
855
+			sourceTree = BUILT_PRODUCTS_DIR;
856
+		};
857
+		E504607B227748DD00212BD8 /* libjsiexecutor-tvOS.a */ = {
818 858
 			isa = PBXReferenceProxy;
819 859
 			fileType = archive.ar;
820
-			path = libprivatedata.a;
821
-			remoteRef = E506412420A3138100EC769F /* PBXContainerItemProxy */;
860
+			path = "libjsiexecutor-tvOS.a";
861
+			remoteRef = E504607A227748DD00212BD8 /* PBXContainerItemProxy */;
822 862
 			sourceTree = BUILT_PRODUCTS_DIR;
823 863
 		};
824 864
 		E8CB6AA81FF10BC4007C82EF /* libthird-party.a */ = {
@@ -876,7 +916,7 @@
876 916
 			);
877 917
 			runOnlyForDeploymentPostprocessing = 0;
878 918
 			shellPath = /bin/sh;
879
-			shellScript = "export NODE_BINARY=node\n../../node_modules/react-native/scripts/react-native-xcode.sh ./index.js";
919
+			shellScript = "export NODE_BINARY=node\n../../node_modules/react-native/scripts/react-native-xcode.sh ./index.js\n";
880 920
 		};
881 921
 /* End PBXShellScriptBuildPhase section */
882 922
 

+ 3
- 1
playground/src/screens/LifecycleScreen.js View File

@@ -37,7 +37,9 @@ class LifecycleScreen extends React.Component {
37 37
   }
38 38
 
39 39
   componentWillUnmount() {
40
-    alert('componentWillUnmount'); // eslint-disable-line no-alert
40
+    setTimeout(() => {
41
+      alert('componentWillUnmount'); // eslint-disable-line no-alert
42
+    }, 100); 
41 43
   }
42 44
 
43 45
   navigationButtonPressed(id) {

+ 0
- 6
scripts/test-e2e.js View File

@@ -10,17 +10,11 @@ const multi = _.includes(process.argv, '--multi');
10 10
 run();
11 11
 
12 12
 function run() {
13
-    const platform = android ? `android` : `ios`;
14 13
     const prefix = android ? `android.emu` : `ios.sim`;
15 14
     const suffix = release ? `release` : `debug`;
16 15
     const configuration = `${prefix}.${suffix}`;
17 16
     const headless$ = android ? headless ? `--headless` : `` : ``;
18 17
     const workers = multi ? 3 : 1;
19
-    
20
-    if (platform === 'android' && process.env.JENKINS_CI) {
21
-        const sdkmanager = '/usr/local/share/android-sdk/tools/bin/sdkmanager';
22
-        exec.execSync(`echo y | ${sdkmanager} --update && echo y | ${sdkmanager} --licenses`);
23
-    }
24 18
 
25 19
     if (!skipBuild) {
26 20
         exec.execSync(`detox build --configuration ${configuration}`);

+ 5
- 1
scripts/test-unit.js View File

@@ -14,7 +14,11 @@ function run() {
14 14
 
15 15
 function runAndroidUnitTests() {
16 16
   const conf = release ? 'testReactNative57_5ReleaseUnitTest' : 'testReactNative57_5DebugUnitTest';
17
-
17
+  if (android && process.env.JENKINS_CI) {
18
+    const sdkmanager = '/usr/local/share/android-sdk/tools/bin/sdkmanager';
19
+    exec.execSync(`yes | ${sdkmanager} --licenses`);
20
+    // exec.execSync(`echo y | ${sdkmanager} --update && echo y | ${sdkmanager} --licenses`);
21
+  }
18 22
   exec.execSync(`cd lib/android && ./gradlew ${conf}`);
19 23
 }
20 24