perf(efficiency): 接入真实CPU能量并隔离展示与采样需求
This commit is contained in:
@@ -55,14 +55,14 @@ import Foundation
|
||||
let store = MetricsStore()
|
||||
store.setPanelVisible(true)
|
||||
for _ in 0..<40 {
|
||||
if store.snapshot.processes != nil { break }
|
||||
if store.processSnapshot != nil { break }
|
||||
try? await Task.sleep(for: .milliseconds(200))
|
||||
}
|
||||
precondition(store.snapshot.processes?.readable ?? 0 > 0)
|
||||
precondition(store.processSnapshot?.readable ?? 0 > 0)
|
||||
store.setPanelVisible(false)
|
||||
precondition(store.snapshot.processes == nil)
|
||||
precondition(store.processSnapshot == nil)
|
||||
try? await Task.sleep(for: .milliseconds(2200))
|
||||
precondition(store.snapshot.processes == nil)
|
||||
precondition(store.processSnapshot == nil)
|
||||
store.togglePause()
|
||||
print("PASS: process CPU boundaries/live baseline, GPU range, VPN total exclusion, bounded interface history, visibility reset")
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user