فینورا پرو - سامانه جامع حسابداری و صدور فاکتور
ci(a02): reject malformed PowerShell before migration synthetic and native SQL gates
davoodmehraban89 committed
Oct 30, 2026 at 22:33 UTC
5e99c2728ffaaa99b1550586553eb7f6c32ff42b
1 file changed
+15
.github/workflows/pr-quality-gates.yml
+15
@@ -61,6 +61,21 @@ jobs:
61
run: npm ci
62
- name: Windows integration regression
63
run: npm test
64
+ - name: Parse every A02 PowerShell script without executing owner data
65
+ shell: pwsh
66
+ run: |
67
+ $output = & powershell.exe -NoProfile -NonInteractive -ExecutionPolicy Bypass -File './scripts/a02-powershell-parse-gate.ps1'
68
+ if ($LASTEXITCODE -ne 0) { throw 'A02 PowerShell parser gate failed' }
69
+ $report = ($output | Out-String | ConvertFrom-Json)
70
+ if ($report.status -ne 'a02-all-powershell-parser-gates-passed' -or
71
+ $report.checkedScripts -lt 7 -or
72
+ $report.malformedSyntheticScriptRejected -ne $true -or
73
+ $report.scriptsExecuted -ne $false -or
74
+ $report.ownerBackupUsed -ne $false -or
75
+ $report.sqlConnected -ne $false -or
76
+ $report.canImport -ne $false) {
77
+ throw 'A02 PowerShell parser control contract invalid'
78
+ }
79
- name: A02 SQL backup preflight selftest (read-only; no SQL instance/data)
80
shell: pwsh
81
run: |