فینورا پرو - سامانه جامع حسابداری و صدور فاکتور
test(A04): orchestrate real crash and restart on separate Windows profile
davoodmehraban89 committed
Oct 16, 2026 at 23:07 UTC
63fe42b9681fe8927e5fe23c9a0a2f87f326b8d4
1 file changed
+11
scripts/windows-vm-native-lab.ps1
+11
@@ -151,6 +151,17 @@ try {
151
$nativePerformance = Run-Native $freshExe $performanceData 'benchmark' $CandidateVersion
152
$summary.nativePerformance = $nativePerformance.nativePerformance
153
154
+ # A04 destructive fault injection is strictly confined to a disposable
155
+ # Windows VM profile. Abruptly kill the native app during genuine importAll,
156
+ # reopen SAME persistent profile and check not one staged row committed.
157
+ $crashData = Join-Path $lab 'webview2-crash-restore-profile'
158
+ $armed = Run-Native $freshExe $crashData 'crash-arm' $CandidateVersion
159
+ if (!$armed.crashInjected.realWindowsProcessKilled) {
160
+ throw 'Native restore process was not genuinely force-terminated'
161
+ }
162
+ $crashVerified = Run-Native $freshExe $crashData 'crash-verify' $CandidateVersion
163
+ $summary.crashRestoreRollback = $crashVerified.crashRollback
164
+
165
$summary.status = 'PASSED'
166
Write-Output 'Verified fresh installation, NSIS in-place upgrade, retained v6 records, native login and Windows DPAPI'
167
Cleanup-Installed $freshDir