Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
45 changes: 26 additions & 19 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -61,24 +61,24 @@ jobs:
- [iPadOS, 18, 6]
- [iPadOS, 26, 0]

- [macCatalyst, 15, 0]
- [macOS, 15, 0]

- [tvOS, 15, 4]
- [tvOS, 16, 4]
- [tvOS, 17, 5]
- [tvOS, 18, 5]
- [tvOS, 26, 0]

- [visionOS, 1, 2]
- [visionOS, 2, 5]
- [visionOS, 26, 0]

- [watchOS, 8, 5]
- [watchOS, 9, 4]
- [watchOS, 10, 5]
- [watchOS, 11, 5]
- [watchOS, 26, 0]

- [macOS, 15, 0]
# - [macOS, 26, 0]

- [visionOS, 1, 2]
- [visionOS, 2, 5]
- [visionOS, 26, 0]
steps:
- name: Git Checkout
uses: actions/checkout@v5
Expand All @@ -97,13 +97,20 @@ jobs:
else
case "$PLATFORM" in
iOS) SCRIPT_PLATFORM=ios ;;
macOS) SCRIPT_PLATFORM=macos ;;
macCatalyst) SCRIPT_PLATFORM=mac-catalyst ;;
tvOS) SCRIPT_PLATFORM=tvos ;;
watchOS) SCRIPT_PLATFORM=watchos ;;
visionOS) SCRIPT_PLATFORM=visionos ;;
macOS) SCRIPT_PLATFORM=macos ;;
watchOS) SCRIPT_PLATFORM=watchos ;;
esac
fi

if [ "$PLATFORM" = "macCatalyst" ]; then
XCB_PLATFORM="mac-catalyst"
else
XCB_PLATFORM="$PLATFORM"
fi

RUNTIME="$PLATFORM $MAJOR.$MINOR"

echo "PLATFORM=$PLATFORM" >> $GITHUB_ENV
Expand All @@ -112,7 +119,7 @@ jobs:
echo "RUNTIME=$RUNTIME" >> $GITHUB_ENV
echo "SCRIPT_PLATFORM=$SCRIPT_PLATFORM" >> $GITHUB_ENV

- if: ${{ env.PLATFORM != 'macOS' }}
- if: ${{ env.PLATFORM != 'macCatalyst' && env.PLATFORM != 'macOS' }}
name: Check for ${{ env.RUNTIME }} runtime
run: |
if xcrun simctl list runtimes | grep -q "$RUNTIME"; then
Expand Down Expand Up @@ -140,7 +147,7 @@ jobs:
max_attempts: 3
command: sudo xcodes runtimes install "$RUNTIME"

- if: ${{ env.PLATFORM != 'macOS' }}
- if: ${{ env.PLATFORM != 'macCatalyst' && env.PLATFORM != 'macOS' }}
name: Create Required Simulators
run: |
set -eo pipefail
Expand All @@ -162,7 +169,7 @@ jobs:
uses: davdroman/xcodebuild@destination
with:
xcode: ~26.0
platform: ${{ env.PLATFORM }}
platform: ${{ env.XCB_PLATFORM }}
platform-version: ~${{ env.MAJOR }}.${{ env.MINOR }}
destination: ${{ env.SIM_UDID }}
action: build
Expand All @@ -175,7 +182,7 @@ jobs:
uses: davdroman/xcodebuild@destination
with:
xcode: ~26.0
platform: ${{ env.PLATFORM }}
platform: ${{ env.XCB_PLATFORM }}
platform-version: ~${{ env.MAJOR }}.${{ env.MINOR }}
destination: ${{ env.SIM_UDID }}
action: build
Expand All @@ -188,7 +195,7 @@ jobs:
uses: davdroman/xcodebuild@destination
with:
xcode: ~26.0
platform: ${{ env.PLATFORM }}
platform: ${{ env.XCB_PLATFORM }}
platform-version: ~${{ env.MAJOR }}.${{ env.MINOR }}
destination: ${{ env.SIM_UDID }}
action: test
Expand All @@ -203,20 +210,20 @@ jobs:
strategy:
fail-fast: false
matrix:
platform: [iOS, macOS, tvOS, watchOS, visionOS, macCatalyst]
platform: [iOS, macCatalyst, macOS, tvOS, visionOS, watchOS]
include:
- platform: iOS
destination: "generic/platform=iOS"
- platform: macCatalyst
destination: "platform=macOS,variant=Mac Catalyst"
- platform: macOS
destination: "generic/platform=macOS"
- platform: tvOS
destination: "generic/platform=tvOS"
- platform: watchOS
destination: "generic/platform=watchOS"
- platform: visionOS
destination: "generic/platform=visionOS"
- platform: macCatalyst
destination: "platform=macOS,variant=Mac Catalyst"
- platform: watchOS
destination: "generic/platform=watchOS"
steps:
- name: Git Checkout
uses: actions/checkout@v5
Expand Down
2 changes: 2 additions & 0 deletions Examples/Showcase/Showcase/Controls.swift
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,7 @@ struct ControlsShowcase: View {
#endif
}

#if !targetEnvironment(macCatalyst)
HStack {
Slider(value: $sliderValue, in: 0...100)
#if os(iOS)
Expand All @@ -97,6 +98,7 @@ struct ControlsShowcase: View {
}
#endif
}
#endif

HStack {
Stepper(onIncrement: {}, onDecrement: {}) {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "2600"
version = "1.3">
version = "1.7">
<BuildAction
parallelizeBuildables = "YES"
buildImplicitDependencies = "YES">
buildImplicitDependencies = "YES"
buildArchitectures = "Automatic">
<BuildActionEntries>
<BuildActionEntry
buildForTesting = "YES"
Expand All @@ -26,9 +27,8 @@
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
shouldUseLaunchSchemeArgsEnv = "YES">
<Testables>
</Testables>
shouldUseLaunchSchemeArgsEnv = "YES"
shouldAutocreateTestPlan = "YES">
</TestAction>
<LaunchAction
buildConfiguration = "Debug"
Expand Down
9 changes: 0 additions & 9 deletions Tests/Package.swift

This file was deleted.

20 changes: 12 additions & 8 deletions Tests/TestFramework/TestFramework.swift
Original file line number Diff line number Diff line change
@@ -1,9 +1,13 @@
//
// TestFramework.swift
// TestFramework
//
// Created by David Roman on 30/07/2025.
//

import Foundation
internal import SwiftUI
internal import SwiftUIIntrospect

struct TestView: View {
var body: some View {
Text("Hello, World!")
#if os(iOS) || os(tvOS) || os(visionOS)
.introspect(.view, on: .iOS(.v13, .v14, .v15, .v16, .v17, .v18, .v26), .tvOS(.v13, .v14, .v15, .v16, .v17, .v18, .v26), .visionOS(.v1, .v2, .v26), customize: { _ in })
#elseif os(macOS)
.introspect(.view, on: .macOS(.v10_15, .v11, .v12, .v13, .v14, .v15, .v26), customize: { _ in })
#endif
}
}
Loading
Loading