Skip to content

Commit

Permalink
Apple TV support 2: Xcode projects and CI (scripts/objc-test.sh)
Browse files Browse the repository at this point in the history
Summary:
* Motivation *

Second PR for Apple TV support.

* Test plan *

Apple TV tests have been added to scripts/objc-test.sh
Closes #10227

Differential Revision: D3974064

Pulled By: javache

fbshipit-source-id: 36dffb4517efa489e40fa713a30655d1d76ef646
  • Loading branch information
douglowder authored and Facebook Github Bot committed Oct 5, 2016
1 parent 91d266b commit 8622998
Show file tree
Hide file tree
Showing 22 changed files with 2,026 additions and 22 deletions.
35 changes: 35 additions & 0 deletions Examples/UIExplorer/UIExplorer-tvOS/Info.plist
@@ -0,0 +1,35 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>CFBundleDevelopmentRegion</key>
<string>en</string>
<key>CFBundleExecutable</key>
<string>$(EXECUTABLE_NAME)</string>
<key>CFBundleIdentifier</key>
<string>$(PRODUCT_BUNDLE_IDENTIFIER)</string>
<key>NSAppTransportSecurity</key>
<dict>
<key>NSAllowsArbitraryLoads</key>
<true/>
</dict>
<key>CFBundleInfoDictionaryVersion</key>
<string>6.0</string>
<key>CFBundleName</key>
<string>$(PRODUCT_NAME)</string>
<key>CFBundlePackageType</key>
<string>APPL</string>
<key>CFBundleShortVersionString</key>
<string>1.0</string>
<key>CFBundleVersion</key>
<string>1</string>
<key>LSRequiresIPhoneOS</key>
<true/>
<key>UIRequiredDeviceCapabilities</key>
<array>
<string>arm64</string>
</array>
<key>UIUserInterfaceStyle</key>
<string>Automatic</string>
</dict>
</plist>
595 changes: 595 additions & 0 deletions Examples/UIExplorer/UIExplorer.xcodeproj/project.pbxproj

Large diffs are not rendered by default.

@@ -0,0 +1,118 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "0800"
version = "1.3">
<BuildAction
parallelizeBuildables = "YES"
buildImplicitDependencies = "YES">
<BuildActionEntries>
<BuildActionEntry
buildForTesting = "YES"
buildForRunning = "YES"
buildForProfiling = "YES"
buildForArchiving = "YES"
buildForAnalyzing = "YES">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "2DD3238F1DA2DD8A000FE1B8"
BuildableName = "UIExplorer-tvOS.app"
BlueprintName = "UIExplorer-tvOS"
ReferencedContainer = "container:UIExplorer.xcodeproj">
</BuildableReference>
</BuildActionEntry>
</BuildActionEntries>
</BuildAction>
<TestAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
shouldUseLaunchSchemeArgsEnv = "YES">
<Testables>
<TestableReference
skipped = "NO">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "2DD323A41DA2DD8B000FE1B8"
BuildableName = "UIExplorer-tvOSUnitTests.xctest"
BlueprintName = "UIExplorer-tvOSUnitTests"
ReferencedContainer = "container:UIExplorer.xcodeproj">
</BuildableReference>
</TestableReference>
<TestableReference
skipped = "NO">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "2D4624C11DA2EA6900C74D09"
BuildableName = "UIExplorer-tvOSIntegrationTests.xctest"
BlueprintName = "UIExplorer-tvOSIntegrationTests"
ReferencedContainer = "container:UIExplorer.xcodeproj">
</BuildableReference>
</TestableReference>
</Testables>
<MacroExpansion>
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "2DD3238F1DA2DD8A000FE1B8"
BuildableName = "UIExplorer-tvOS.app"
BlueprintName = "UIExplorer-tvOS"
ReferencedContainer = "container:UIExplorer.xcodeproj">
</BuildableReference>
</MacroExpansion>
<AdditionalOptions>
</AdditionalOptions>
</TestAction>
<LaunchAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
launchStyle = "0"
useCustomWorkingDirectory = "NO"
ignoresPersistentStateOnLaunch = "NO"
debugDocumentVersioning = "YES"
debugServiceExtension = "internal"
allowLocationSimulation = "YES">
<BuildableProductRunnable
runnableDebuggingMode = "0">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "2DD3238F1DA2DD8A000FE1B8"
BuildableName = "UIExplorer-tvOS.app"
BlueprintName = "UIExplorer-tvOS"
ReferencedContainer = "container:UIExplorer.xcodeproj">
</BuildableReference>
</BuildableProductRunnable>
<EnvironmentVariables>
<EnvironmentVariable
key = "CI_USE_PACKAGER"
value = "1"
isEnabled = "YES">
</EnvironmentVariable>
</EnvironmentVariables>
<AdditionalOptions>
</AdditionalOptions>
</LaunchAction>
<ProfileAction
buildConfiguration = "Release"
shouldUseLaunchSchemeArgsEnv = "YES"
savedToolIdentifier = ""
useCustomWorkingDirectory = "NO"
debugDocumentVersioning = "YES">
<BuildableProductRunnable
runnableDebuggingMode = "0">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "2DD3238F1DA2DD8A000FE1B8"
BuildableName = "UIExplorer-tvOS.app"
BlueprintName = "UIExplorer-tvOS"
ReferencedContainer = "container:UIExplorer.xcodeproj">
</BuildableReference>
</BuildableProductRunnable>
</ProfileAction>
<AnalyzeAction
buildConfiguration = "Debug">
</AnalyzeAction>
<ArchiveAction
buildConfiguration = "Release"
revealArchiveInOrganizer = "YES">
</ArchiveAction>
</Scheme>
@@ -1,5 +1,15 @@
{
"images" : [
{
"idiom" : "iphone",
"size" : "20x20",
"scale" : "2x"
},
{
"idiom" : "iphone",
"size" : "20x20",
"scale" : "3x"
},
{
"size" : "29x29",
"idiom" : "iphone",
Expand Down Expand Up @@ -41,4 +51,4 @@
"version" : 1,
"author" : "xcode"
}
}
}
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Expand Up @@ -45,12 +45,14 @@ - (void)test##name \
[_runner runTest:_cmd module:@#name]; \
}

#if !TARGET_OS_TV // None of these will run in tvOS due to StatusBar not existing
RCT_TEST(ViewExample)
RCT_TEST(LayoutExample)
RCT_TEST(TextExample)
RCT_TEST(SwitchExample)
RCT_TEST(SliderExample)
RCT_TEST(TabBarExample)
#endif

- (void)testZZZNotInRecordMode
{
Expand Down
126 changes: 126 additions & 0 deletions Libraries/Image/RCTImage.xcodeproj/project.pbxproj
Expand Up @@ -14,13 +14,33 @@
139A38841C4D587C00862840 /* RCTResizeMode.m in Sources */ = {isa = PBXBuildFile; fileRef = 139A38831C4D587C00862840 /* RCTResizeMode.m */; };
13EF7F7F1BC825B1003F47DD /* RCTLocalAssetImageLoader.m in Sources */ = {isa = PBXBuildFile; fileRef = 13EF7F7E1BC825B1003F47DD /* RCTLocalAssetImageLoader.m */; };
143879381AAD32A300F088A5 /* RCTImageLoader.m in Sources */ = {isa = PBXBuildFile; fileRef = 143879371AAD32A300F088A5 /* RCTImageLoader.m */; };
2D3B5F1A1D9B0D0400451313 /* RCTImageCache.m in Sources */ = {isa = PBXBuildFile; fileRef = CCD34C261D4B8FE900268922 /* RCTImageCache.m */; };
2D3B5F1B1D9B0D0700451313 /* RCTImageBlurUtils.m in Sources */ = {isa = PBXBuildFile; fileRef = EEF314711C9B0DD30049118E /* RCTImageBlurUtils.m */; };
2D3B5F1C1D9B0D1300451313 /* RCTResizeMode.m in Sources */ = {isa = PBXBuildFile; fileRef = 139A38831C4D587C00862840 /* RCTResizeMode.m */; };
2D3B5F1D1D9B0D1300451313 /* RCTLocalAssetImageLoader.m in Sources */ = {isa = PBXBuildFile; fileRef = 13EF7F7E1BC825B1003F47DD /* RCTLocalAssetImageLoader.m */; };
2D3B5F1E1D9B0D1300451313 /* RCTGIFImageDecoder.m in Sources */ = {isa = PBXBuildFile; fileRef = 1304D5B11AA8C50D0002E2BE /* RCTGIFImageDecoder.m */; };
2D3B5F1F1D9B0D1300451313 /* RCTImageEditingManager.m in Sources */ = {isa = PBXBuildFile; fileRef = 354631671B69857700AA0B86 /* RCTImageEditingManager.m */; };
2D3B5F201D9B0D1300451313 /* RCTImageLoader.m in Sources */ = {isa = PBXBuildFile; fileRef = 143879371AAD32A300F088A5 /* RCTImageLoader.m */; };
2D3B5F211D9B0D1300451313 /* RCTImageView.m in Sources */ = {isa = PBXBuildFile; fileRef = 1304D5A81AA8C4A30002E2BE /* RCTImageView.m */; };
2D3B5F221D9B0D1300451313 /* RCTImageViewManager.m in Sources */ = {isa = PBXBuildFile; fileRef = 1304D5AA1AA8C4A30002E2BE /* RCTImageViewManager.m */; };
2D3B5F231D9B0D1300451313 /* RCTImageStoreManager.m in Sources */ = {isa = PBXBuildFile; fileRef = 35123E6A1B59C99D00EBAD80 /* RCTImageStoreManager.m */; };
2D3B5F241D9B0D1300451313 /* RCTImageUtils.m in Sources */ = {isa = PBXBuildFile; fileRef = 134B00A11B54232B00EC8DFB /* RCTImageUtils.m */; };
35123E6B1B59C99D00EBAD80 /* RCTImageStoreManager.m in Sources */ = {isa = PBXBuildFile; fileRef = 35123E6A1B59C99D00EBAD80 /* RCTImageStoreManager.m */; };
354631681B69857700AA0B86 /* RCTImageEditingManager.m in Sources */ = {isa = PBXBuildFile; fileRef = 354631671B69857700AA0B86 /* RCTImageEditingManager.m */; };
CCD34C271D4B8FE900268922 /* RCTImageCache.m in Sources */ = {isa = PBXBuildFile; fileRef = CCD34C261D4B8FE900268922 /* RCTImageCache.m */; };
EEF314721C9B0DD30049118E /* RCTImageBlurUtils.m in Sources */ = {isa = PBXBuildFile; fileRef = EEF314711C9B0DD30049118E /* RCTImageBlurUtils.m */; };
/* End PBXBuildFile section */

/* Begin PBXCopyFilesBuildPhase section */
2D2A28381D9B042B00D4039D /* CopyFiles */ = {
isa = PBXCopyFilesBuildPhase;
buildActionMask = 2147483647;
dstPath = "include/$(PRODUCT_NAME)";
dstSubfolderSpec = 16;
files = (
);
runOnlyForDeploymentPostprocessing = 0;
};
58B5115B1A9E6B3D00147676 /* CopyFiles */ = {
isa = PBXCopyFilesBuildPhase;
buildActionMask = 2147483647;
Expand All @@ -47,6 +67,7 @@
13EF7F7E1BC825B1003F47DD /* RCTLocalAssetImageLoader.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTLocalAssetImageLoader.m; sourceTree = "<group>"; };
143879361AAD32A300F088A5 /* RCTImageLoader.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTImageLoader.h; sourceTree = "<group>"; };
143879371AAD32A300F088A5 /* RCTImageLoader.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTImageLoader.m; sourceTree = "<group>"; };
2D2A283A1D9B042B00D4039D /* libRCTImage-tvOS.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libRCTImage-tvOS.a"; sourceTree = BUILT_PRODUCTS_DIR; };
35123E691B59C99D00EBAD80 /* RCTImageStoreManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTImageStoreManager.h; sourceTree = "<group>"; };
35123E6A1B59C99D00EBAD80 /* RCTImageStoreManager.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTImageStoreManager.m; sourceTree = "<group>"; };
354631661B69857700AA0B86 /* RCTImageEditingManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTImageEditingManager.h; sourceTree = "<group>"; };
Expand All @@ -59,6 +80,13 @@
/* End PBXFileReference section */

/* Begin PBXFrameworksBuildPhase section */
2D2A28371D9B042B00D4039D /* Frameworks */ = {
isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647;
files = (
);
runOnlyForDeploymentPostprocessing = 0;
};
58B5115A1A9E6B3D00147676 /* Frameworks */ = {
isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647;
Expand Down Expand Up @@ -104,13 +132,31 @@
isa = PBXGroup;
children = (
58B5115D1A9E6B3D00147676 /* libRCTImage.a */,
2D2A283A1D9B042B00D4039D /* libRCTImage-tvOS.a */,
);
name = Products;
sourceTree = "<group>";
};
/* End PBXGroup section */

/* Begin PBXNativeTarget section */
2D2A28391D9B042B00D4039D /* RCTImage-tvOS */ = {
isa = PBXNativeTarget;
buildConfigurationList = 2D2A28421D9B042B00D4039D /* Build configuration list for PBXNativeTarget "RCTImage-tvOS" */;
buildPhases = (
2D2A28361D9B042B00D4039D /* Sources */,
2D2A28371D9B042B00D4039D /* Frameworks */,
2D2A28381D9B042B00D4039D /* CopyFiles */,
);
buildRules = (
);
dependencies = (
);
name = "RCTImage-tvOS";
productName = "RCTImage-tvOS";
productReference = 2D2A283A1D9B042B00D4039D /* libRCTImage-tvOS.a */;
productType = "com.apple.product-type.library.static";
};
58B5115C1A9E6B3D00147676 /* RCTImage */ = {
isa = PBXNativeTarget;
buildConfigurationList = 58B511711A9E6B3D00147676 /* Build configuration list for PBXNativeTarget "RCTImage" */;
Expand All @@ -137,6 +183,10 @@
LastUpgradeCheck = 0610;
ORGANIZATIONNAME = Facebook;
TargetAttributes = {
2D2A28391D9B042B00D4039D = {
CreatedOnToolsVersion = 8.0;
ProvisioningStyle = Automatic;
};
58B5115C1A9E6B3D00147676 = {
CreatedOnToolsVersion = 6.1.1;
};
Expand All @@ -155,11 +205,30 @@
projectRoot = "";
targets = (
58B5115C1A9E6B3D00147676 /* RCTImage */,
2D2A28391D9B042B00D4039D /* RCTImage-tvOS */,
);
};
/* End PBXProject section */

/* Begin PBXSourcesBuildPhase section */
2D2A28361D9B042B00D4039D /* Sources */ = {
isa = PBXSourcesBuildPhase;
buildActionMask = 2147483647;
files = (
2D3B5F231D9B0D1300451313 /* RCTImageStoreManager.m in Sources */,
2D3B5F1A1D9B0D0400451313 /* RCTImageCache.m in Sources */,
2D3B5F1D1D9B0D1300451313 /* RCTLocalAssetImageLoader.m in Sources */,
2D3B5F1F1D9B0D1300451313 /* RCTImageEditingManager.m in Sources */,
2D3B5F1E1D9B0D1300451313 /* RCTGIFImageDecoder.m in Sources */,
2D3B5F1C1D9B0D1300451313 /* RCTResizeMode.m in Sources */,
2D3B5F221D9B0D1300451313 /* RCTImageViewManager.m in Sources */,
2D3B5F211D9B0D1300451313 /* RCTImageView.m in Sources */,
2D3B5F201D9B0D1300451313 /* RCTImageLoader.m in Sources */,
2D3B5F1B1D9B0D0700451313 /* RCTImageBlurUtils.m in Sources */,
2D3B5F241D9B0D1300451313 /* RCTImageUtils.m in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
58B511591A9E6B3D00147676 /* Sources */ = {
isa = PBXSourcesBuildPhase;
buildActionMask = 2147483647;
Expand All @@ -181,6 +250,54 @@
/* End PBXSourcesBuildPhase section */

/* Begin XCBuildConfiguration section */
2D2A28401D9B042B00D4039D /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
CLANG_ANALYZER_NONNULL = YES;
CLANG_WARN_DOCUMENTATION_COMMENTS = YES;
CLANG_WARN_INFINITE_RECURSION = YES;
CLANG_WARN_SUSPICIOUS_MOVES = YES;
DEBUG_INFORMATION_FORMAT = dwarf;
ENABLE_TESTABILITY = YES;
GCC_NO_COMMON_BLOCKS = YES;
HEADER_SEARCH_PATHS = (
"$(inherited)",
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include,
"$(SRCROOT)/../../React/**",
"$(SRCROOT)/../Network/**",
);
OTHER_LDFLAGS = "-ObjC";
PRODUCT_NAME = "$(TARGET_NAME)";
SDKROOT = appletvos;
SKIP_INSTALL = YES;
TVOS_DEPLOYMENT_TARGET = 9.2;
};
name = Debug;
};
2D2A28411D9B042B00D4039D /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
CLANG_ANALYZER_NONNULL = YES;
CLANG_WARN_DOCUMENTATION_COMMENTS = YES;
CLANG_WARN_INFINITE_RECURSION = YES;
CLANG_WARN_SUSPICIOUS_MOVES = YES;
COPY_PHASE_STRIP = NO;
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
GCC_NO_COMMON_BLOCKS = YES;
HEADER_SEARCH_PATHS = (
"$(inherited)",
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include,
"$(SRCROOT)/../../React/**",
"$(SRCROOT)/../Network/**",
);
OTHER_LDFLAGS = "-ObjC";
PRODUCT_NAME = "$(TARGET_NAME)";
SDKROOT = appletvos;
SKIP_INSTALL = YES;
TVOS_DEPLOYMENT_TARGET = 9.2;
};
name = Release;
};
58B5116F1A9E6B3D00147676 /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
Expand Down Expand Up @@ -312,6 +429,15 @@
/* End XCBuildConfiguration section */

/* Begin XCConfigurationList section */
2D2A28421D9B042B00D4039D /* Build configuration list for PBXNativeTarget "RCTImage-tvOS" */ = {
isa = XCConfigurationList;
buildConfigurations = (
2D2A28401D9B042B00D4039D /* Debug */,
2D2A28411D9B042B00D4039D /* Release */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
58B511581A9E6B3D00147676 /* Build configuration list for PBXProject "RCTImage" */ = {
isa = XCConfigurationList;
buildConfigurations = (
Expand Down

0 comments on commit 8622998

Please sign in to comment.