Skip to content

Commit

Permalink
feat: add visionOS as separate target to fix iOS tests (#31)
Browse files Browse the repository at this point in the history
* feat: add visionOS as separate target to fix iOS tests

* fix: disable multiple windows support

* feat: add visionOS App Icon

* fix: creating Release build
  • Loading branch information
okwasniewski committed Mar 6, 2024
1 parent bbbc383 commit c7cb7ea
Show file tree
Hide file tree
Showing 14 changed files with 535 additions and 49 deletions.
8 changes: 6 additions & 2 deletions packages/rn-tester/Podfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
require_relative '../react-native/scripts/react_native_pods'

source 'https://cdn.cocoapods.org/'
platform :visionos, min_visionos_version_supported
platform :ios, min_ios_version_supported

cmake_path = `command -v cmake`

Expand Down Expand Up @@ -39,7 +39,6 @@ def pods(target_name, options = {})

# Hermes is now enabled by default.
# The following line will only disable Hermes if the USE_HERMES envvar is SET to a value other than 1 (e.g. USE_HERMES=0).
# TODO: Make hermes work
hermes_enabled = !ENV.has_key?('USE_HERMES') || ENV['USE_HERMES'] == '1'
puts "Configuring #{target_name} with Fabric #{fabric_enabled ? "enabled" : "disabled"}.#{hermes_enabled ? " Using Hermes engine." : ""}"

Expand Down Expand Up @@ -67,6 +66,11 @@ target 'RNTester' do
pods('RNTester')
end

target('RNTester-visionOS') do
platform :visionos, min_visionos_version_supported
pods('RNTester-visionOS')
end

target 'RNTesterUnitTests' do
pods('RNTesterUnitTests')
pod 'React-RCTTest', :path => "./RCTTest"
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
{
"images" : [
{
"filename" : "back.jpg",
"idiom" : "vision",
"scale" : "2x"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"info" : {
"author" : "xcode",
"version" : 1
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
{
"info" : {
"author" : "xcode",
"version" : 1
},
"layers" : [
{
"filename" : "Front.solidimagestacklayer"
},
{
"filename" : "Middle.solidimagestacklayer"
},
{
"filename" : "Back.solidimagestacklayer"
}
]
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
{
"images" : [
{
"filename" : "front.png",
"idiom" : "vision",
"scale" : "2x"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"info" : {
"author" : "xcode",
"version" : 1
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
{
"images" : [
{
"idiom" : "vision",
"scale" : "2x"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"info" : {
"author" : "xcode",
"version" : 1
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"info" : {
"version" : 1,
"author" : "xcode"
}
}
15 changes: 15 additions & 0 deletions packages/rn-tester/RNTester-visionOS/Info.plist
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
<?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>UIApplicationSceneManifest</key>
<dict>
<key>UIApplicationPreferredDefaultSceneSessionRole</key>
<string>UIWindowSceneSessionRoleApplication</string>
<key>UIApplicationSupportsMultipleScenes</key>
<false/>
<key>UISceneConfigurations</key>
<dict/>
</dict>
</dict>
</plist>
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"info" : {
"author" : "xcode",
"version" : 1
}
}
476 changes: 429 additions & 47 deletions packages/rn-tester/RNTesterPods.xcodeproj/project.pbxproj

Large diffs are not rendered by default.

0 comments on commit c7cb7ea

Please sign in to comment.