Public edition prepared 2026-09-12. Personal/account/contact details are visibly redacted where present. The original SHA256 identifies the captured unredacted full file, not this redacted extract. PUBLIC-SHA256SUMS.txt identifies downloadable public files. This material is not a signed declaration or proof of an Apple-received Build. # S06 Explicit UI test arguments and local sample import Project key: vpn Original relative path: ConfigStudio/App/ConfigStudioApp.swift Captured: 2026-09-12T18:57:15+08:00 Original full-file SHA256: 4dfb80e53764be28f98a0adca6e2fe2b03f63dd8d58e958b7cf7d70efda77985 Evidence level: local source excerpt Build correspondence: not yet established with an Apple-received binary. Line numbers refer to the captured original file. Gaps are explicitly marked. No source code was changed. ## Original lines 1 to 44 ```text 0001 import SwiftUI 0002 #if DEBUG && targetEnvironment(macCatalyst) 0003 import UIKit 0004 #endif 0005 0006 @main 0007 struct ConfigStudioApp: App { 0008 @Environment(\.scenePhase) private var scenePhase 0009 @StateObject private var model: AppViewModel 0010 init() { 0011 let arguments = ProcessInfo.processInfo.arguments 0012 let isTesting = arguments.contains("-UITesting") 0013 if arguments.contains("-ResetAppLanguageForUITest") { UserDefaults.standard.removeObject(forKey: AppLanguage.storageKey) } 0014 if arguments.contains("-ResetOnboardingForUITest") { UserDefaults.standard.set(false, forKey: "hasCompletedOnboarding") } 0015 else if isTesting { UserDefaults.standard.set(true, forKey: "hasCompletedOnboarding") } 0016 let model = AppViewModel(dependencies: AppDependencies(inMemory: isTesting)) 0017 if arguments.contains("-LoadDemoDataForUITest") { _ = model.loadDemoDataset() } 0018 if arguments.contains("-LoadSubscriptionGroupForUITest"), 0019 let sourceURL = URL(string: "https://provider.example/nodes.yaml") { 0020 let content = """ 0021 trojan://first-password@node-one.example.com:443#Source%20Node%20A 0022 trojan://second-password@node-two.example.com:8443#Source%20Node%20B 0023 """ 0024 let items = model.dependencies.importer.preview(content, fileExtension: nil, existing: []) 0025 _ = try? model.importSubscriptionItems(items.items, source: SubscriptionSourceDescriptor(url: sourceURL)) 0026 } 0027 if let optionIndex = arguments.firstIndex(of: "-InitialTabForUITest"), 0028 arguments.indices.contains(optionIndex + 1), 0029 let tab = AppTab(rawValue: arguments[optionIndex + 1]) { 0030 model.selectedTab = tab 0031 } 0032 if let optionIndex = arguments.firstIndex(of: "-InitialFeatureForUITest"), 0033 arguments.indices.contains(optionIndex + 1), 0034 let route = FeatureRoute(rawValue: arguments[optionIndex + 1]) { 0035 model.present(route) 0036 } 0037 _model = StateObject(wrappedValue: model) 0038 } 0039 var body: some Scene { 0040 WindowGroup { 0041 AppRootView().environmentObject(model) 0042 .task { await AdMobManager.shared.configure() } 0043 .onChange(of: scenePhase) { phase in 0044 model.handleScenePhase(phase) ```