-
Notifications
You must be signed in to change notification settings - Fork 0
72 lines (62 loc) · 1.96 KB
/
swift-test-workflow.yml
File metadata and controls
72 lines (62 loc) · 1.96 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
on:
workflow_call:
inputs:
test-path:
required: true
type: string
job-name:
required: false
type: string
default: Run
permissions:
contents: read
jobs:
test:
name: ${{ inputs.job-name }}
runs-on: ${{ vars.MACOS_RUNNER }}
timeout-minutes: 20
defaults:
run:
working-directory: platforms/swift
steps:
- name: Checkout Repository
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
- name: Switch to Xcode 26.2
run: |
sudo xcode-select --switch /Applications/Xcode_26.2.app
echo ""
- name: Display Current Xcode Path
run: |
echo "📍 Current Xcode Path:"
xcode-select -p
echo ""
- name: Display Xcode Version
run: |
echo "🛠️ Xcode Version Information:"
xcrun xcodebuild -version
echo ""
- name: List Available Simulators
run: |
echo "📱 Available iOS Simulator Runtimes:"
echo "=================================="
xcrun simctl list runtimes | grep iOS || true
echo ""
echo "📱 Available Device Types (iPhone only):"
echo "========================================"
xcrun simctl list devicetypes | grep iPhone || true
echo ""
- name: Clean Up Existing Simulators
run: |
echo "🧹 Cleaning up existing simulators..."
xcrun simctl delete all
echo "✅ Cleanup complete"
echo ""
- name: Create Test Simulator
run: |
echo "🔧 Creating new test simulator..."
CURRENT_SIMULATOR_UUID=$(xcrun simctl create TestDevice "iPhone 17 Pro")
echo "✅ Created simulator with UUID: $CURRENT_SIMULATOR_UUID"
echo "CURRENT_SIMULATOR_UUID=$CURRENT_SIMULATOR_UUID" >> $GITHUB_ENV
echo ""
- name: Run Tests
run: ${{ inputs.test-path }}