fix(processes): 对齐活动监视器内存口径与显示单位

This commit is contained in:
2026-11-04 14:28:56 +08:00
parent 44f0415ab7
commit bbec1325a1
23 changed files with 195 additions and 26 deletions
+1 -1
View File
@@ -22,7 +22,7 @@ import Foundation
precondition(ProcessEnergyMonitor.watts(current: invalid, previous: reading(5, at: 10)) == nil)
}
func row(_ id: ProcessIdentity, _ cpu: Double) -> ProcessMetrics {
ProcessMetrics(id: id, name: "fixture", path: nil, cpu: cpu, residentBytes: nil, threads: nil, restricted: false)
ProcessMetrics(id: id, name: "fixture", path: nil, cpu: cpu, footprintBytes: nil, threads: nil, restricted: false)
}
let id2 = ProcessIdentity(pid: 43, seconds: 100, microseconds: 2)
let processes = ProcessSnapshot(date: Date(), enumerated: 3, readable: 2, rows: [row(id, 5), row(id2, 0.01)], failed: false)