Skip to content

ci(apple): build and test the tvOS app on every pull request - #62

Merged
Artic0din merged 22 commits into
mainfrom
ci/apple-tests
Nov 24, 2026
Merged

Artic0din merged 22 commits into
mainfrom
ci/apple-tests

Conversation

@Artic0din

@Artic0din Artic0din commented Nov 23, 2026 •

Copy link
Copy Markdown
Owner

Problem

Related issue: #57, #58, #64
Validation tasks: none

Other clients: Android N/A (Apple CI); Roku N/A (Apple CI); Web N/A (Apple CI)

CI on this repository runs only script tests on Linux.
No pull request is compiled or unit-tested before merge, so bugs that only a build or a test would catch rely on local runs and review bots.

Approach

Adds .github/workflows/apple-tests.yml: a SiloTV build-and-test job on the hosted xcode-27 image the sideload and release workflows use, on pull requests and pushes to main.
It tests only tvOS, because this fork keeps only the Apple TV app.
It pins Xcode 27.1, the version the release workflows build with, installs XcodeGen with the existing pinned action, and runs scripts/apple-test.sh from the PR this one stacks on.
Tests that already fail on main are skipped through SILO_SKIP_TESTS, each with the issue that tracks it, so the job is green on main and red only for new failures.
Each test gets 180 seconds in CI (SILO_TEST_TIMEOUT), because the hosted runner runs the suite about three times slower than a local Mac.

The local test script (#61) is already merged.

Validation

  • actionlint passes.
  • The same command, with the same skip list, passes locally: tvOS 3,755 tests.
  • The hosted test (SiloTV) job passed on every run of this PR before the iOS and Mac jobs were dropped.
  • Hosted run: see this PR's checks. The first run used macos-26, which ships only Xcode 26, and stopped at setup; review caught it and the job now uses xcode-27.

Evidence

Evidence: none, no user-visible change.

Risks

  • Each run uses one macOS runner; the fork is public, so hosted minutes are free.
  • actionlint doesn't list the xcode-27 label yet; the existing release workflows already run on it.

Checklist

  • I read and can explain the complete diff.
  • This pull request addresses one concern.
  • The Evidence section shows every change a user can see, or how I checked a change nobody sees.

AI Disclosure

  • Harness: T3 Code running Claude Code
  • Tool(s): Claude Code; Codex for review
  • Model(s): claude-opus-5-5 (implementation); gpt-6.2-sol (review)
  • Involvement: Fully AI-generated, not yet human verified
  • Adversarial review: independent read-only review of the diff by gpt-6.2-sol before merge; findings and resolutions are added as review comments.

ELI5

Every change now gets built and tested as an Apple TV app on a real Mac before it can be merged.

Running the suites with CODE_SIGNING_ALLOWED=NO strips the Keychain
entitlement: about 150 of the first 1,000 iOS tests failed with
keychain_read_failed(-34018), and a test waiting on the network hung
the run for two hours. Signed locally, the same suites finish in
minutes with 9 iOS and 5 tvOS failures, all tracked separately.

scripts/apple-test.sh regenerates the project, picks a simulator,
signs locally, runs in the US region the expected dates assume, gives
every test a time limit, and accepts test classes and a skip list.
AGENTS.md and docs/mac-builder.md point at it for work on a Mac.
Matching names that start with "Apple TV" missed a renamed Apple TV
simulator. Choose by runtime and family instead, reuse a booted
simulator when there is one, and document SILO_SKIP_TESTS.
CI ran only script tests on Linux, so no pull request was ever
compiled or unit-tested before merge. This job runs
scripts/apple-test.sh for Silo, SiloTV and SiloMac on a hosted macOS
runner with the newest Xcode 27, skipping the tests that already fail
on main, each listed with the issue that tracks it.
…le-only

Review found the name match missed renamed simulators, such as an
Apple TV called Living Room; match the device type identifier instead.
SiloMac now rejects test classes rather than silently ignoring them,
AGENTS.md says it is compile-only, and the new docs section links to
the existing signing explanation instead of repeating it.
The macos-26 image ships only Xcode 26, so every job stopped at setup.
Use the xcode-27 image the sideload and release workflows use, pin the
stable 27.2 rather than the newest install (the image also has a 27.3
beta), and skip only the four PlayerSurfaceLayoutTests that #59 names.
Without XcodeGen installed the check never ran and the script exited
127; validate arguments first so bad input always gets exit 2.

@sourcery-ai sourcery-ai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hey - I've found 1 issue

Prompt for AI Agents
Please address the comments from this code review:

## Individual Comments

### Comment 1
<location path=".github/workflows/apple-tests.yml" line_range="47" />
<code_context>
+      # The stable release this repo builds with locally; the image also carries betas.
+      - name: Select Xcode 27.2
+        run: |
+          sudo xcode-select -s /Applications/Xcode_27.2.app
+          xcodebuild -version
+
</code_context>
<issue_to_address>
**Release compiler remains untested**

A change that builds and passes tests with Xcode 27.2 but fails with Xcode 27.1 passes this workflow and then breaks the release build, so the mismatch is caught only after merge.

Use the same Xcode version as the release workflows, or test both versions.
</issue_to_address>

Fix all in Cursor


Sourcery is free for open source - if you like our reviews please consider sharing them ✨

Comment thread .github/workflows/apple-tests.yml Resolved
Testing with 27.2 while release.yml and sideload-ipa.yml build with
27.1 would let a change that breaks the release compiler pass here.
The hosted runner runs the iOS suite about three times slower than a
local Mac. An ASS renderer test went past the 60-second limit, and the
bearer-rotation playback test missed its fixed 5-second subtitle wait.
Give each test 180 seconds in CI and skip the playback test until #64
fixes its wait.
A local xcconfig that turned signing off would strip the Keychain
entitlement again, so pass CODE_SIGNING_ALLOWED=YES with the ad-hoc
identity, as the CONTRIBUTING simulator recipe does. A booted
simulator on a runtime older than the deployment target in
project.yml was preferred over a usable one; skip those.
The sed pattern only matched double quotes, so a single-quoted or
bare deploymentTarget left the minimum empty and simulator selection
crashed. Accept any quote style and fail with a clear message when
the key is missing.
The lookup ran first, so a project.yml it could not read stopped the
run even though the error told you to set SILO_SIM_ID. Read it only
for automatic selection, and allow a trailing YAML comment.
@Artic0din
Artic0din changed the base branch from test/local-apple-test-script to main November 24, 2026 02:08
This fork keeps only the Apple TV app, so drop the iOS and Mac jobs and
the iOS-only PlayerSurfaceLayoutTests skips.
@Artic0din Artic0din changed the title ci(apple): build and test the iOS, tvOS and Mac apps on pull requests ci(apple): build and test the tvOS app on every pull request Nov 24, 2026
@plaintext-review

plaintext-review Bot commented Nov 24, 2026 •

Copy link
Copy Markdown

Code Review Completed! 🔥

The code review was successfully completed.

Comment thread .github/workflows/apple-tests.yml Resolved
Comment thread .github/workflows/apple-tests.yml Resolved
Xcode re-resolved packages during tests, so a lockfile the release
lanes would reject could pass CI. Pass the same two flags as the
Fastfile.
@plaintext-review

plaintext-review Bot commented Nov 24, 2026 •

Copy link
Copy Markdown

Code Review Completed! 🔥

The code review was successfully completed.

Comment thread scripts/apple-test.sh Resolved
@plaintext-review

plaintext-review Bot commented Nov 24, 2026 •

Copy link
Copy Markdown

Code Review Completed! 🔥

The code review was successfully completed.

Comment thread scripts/apple-test.sh Resolved
@plaintext-review

plaintext-review Bot commented Nov 24, 2026 •

Copy link
Copy Markdown

Code Review Completed! 🔥

The code review was successfully completed.

@Artic0din
Artic0din merged commit ce470f5 into main Nov 24, 2026
4 checks passed
@Artic0din
Artic0din deleted the ci/apple-tests branch November 24, 2026 04:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant