From gpt-5 with max context after explaining the situation and using the test project's code as context:
APNs registration in iOS Simulator does not reliably work in virtualized macOS (GitHub Actions VMs, Anka, etc.). The simulator’s APNs path depends on host hardware services that aren’t fully available/exposed in VMs, so callbacks may never arrive (neither success nor failure). This matches your observation that it always works on bare metal but never in the VM. Simulator APNs registration does not consistently work in virtualized macOS.
Validate notification UI/delivery in CI without APNs. Use xcrun simctl push to inject a notification payload locally (no device token required). Your permission UI test already handles the prompt.
Topic:
Developer Tools & Services
SubTopic:
Xcode
Tags: