Cache CI test run compilations

This commit is contained in:
Stefan Ceriu
2026-08-18 12:50:32 +03:00
parent 5f49c25952
commit 771d10ac6b
3 changed files with 36 additions and 0 deletions
+6
View File
@@ -139,6 +139,12 @@ struct RunTests: AsyncParsableCommand {
command += " -destination 'platform=iOS Simulator,name=\(device),OS=\(osVersion),arch=arm64'"
command += " -resultBundlePath \(resultBundlePath)"
// Use a dedicated compilation cache for incremental builds on CI (as Xcode's DerivedData
// is invalidated by a fresh checkout).
command += " COMPILATION_CACHE_ENABLE_CACHING=YES"
// Store it outside DerivedData so CI can cache just what it needs.
command += " COMPILATION_CACHE_CAS_PATH=$HOME/Library/Developer/Xcode/CompilationCache.noindex"
// Use xcodebuild's native retry support to re-run only failing tests
// instead of re-running the entire suite. retries=0 means no retries (single run).
if retries > 0 {