Skip to content

Complete issue #39 boot diagnostics, telemetry, and boot command #37

Complete issue #39 boot diagnostics, telemetry, and boot command

Complete issue #39 boot diagnostics, telemetry, and boot command #37

Workflow file for this run

name: iOS
on:
pull_request:
push:
branches:
- main
permissions:
contents: read
concurrency:
group: ci-${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
integration-ios:
name: Integration Tests
runs-on: macos-26
timeout-minutes: 80
continue-on-error: true
steps:
- name: Checkout
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
- name: Setup toolchain
uses: ./.github/actions/setup-node-pnpm
- name: Resolve agent-device home
id: ios-agent-home
run: echo "dir=$HOME/.agent-device" >> "$GITHUB_OUTPUT"
- name: Select and start iOS simulator
run: |
UDID="$(
xcrun simctl list devices -j | node -e "
const fs = require('node:fs');
const payload = JSON.parse(fs.readFileSync(0, 'utf8'));
const all = Object.values(payload.devices ?? {}).flat();
const available = all.filter((d) => d.isAvailable);
const preferred =
available.find((d) => d.state === 'Booted') ??
available.find((d) => d.name === 'iPhone 17 Pro') ??
available[0];
if (!preferred?.udid) process.exit(1);
process.stdout.write(preferred.udid);
"
)"
xcrun simctl boot "$UDID" || true
echo "IOS_UDID=$UDID" >> "$GITHUB_ENV"
- name: Build iOS integration artifacts
run: pnpm build:xcuitest
- name: Boot preflight via agent-device
run: |
set -euo pipefail
node --experimental-strip-types src/bin.ts boot --platform ios --udid "$IOS_UDID" --json
env:
AGENT_DEVICE_IOS_BOOT_TIMEOUT_MS: "180000"
AGENT_DEVICE_RETRY_LOGS: "1"
- name: Run iOS integration test
env:
AGENT_DEVICE_DAEMON_TIMEOUT_MS: "300000"
run: node --test test/integration/ios.test.ts
- name: Upload iOS artifacts
if: always()
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2
with:
name: ios-artifacts
if-no-files-found: ignore
path: |
${{ steps.ios-agent-home.outputs.dir }}/daemon.log
${{ steps.ios-agent-home.outputs.dir }}/sessions/**
test/artifacts/**
test/screenshots/**