فینورا پرو - سامانه جامع حسابداری و صدور فاکتور
test(q01): lock safe native action and cancel-without-write audit coverage
davoodmehraban89 committed
Oct 31, 2026 at 07:59 UTC
8500314d7c1b047bc7286677d6668ddbb262a412
1 file changed
+14
tests/ui-control-structure.test.mjs
+14
@@ -126,6 +126,20 @@ test('A01: financial confirm never executes twice after Confirm/Cancel or while
126
assert.ok(runner.includes('modalKeyboard.staleFinancialConfirmIgnored'));
127
});
128
129
+test('Q01: native audit verifies safe routes, filters, edit previews and cancel-only destructive prompts', () => {
130
+ const audit=fs.readFileSync(path.join(root,'tests','windows-vm-ui-interaction-audit-browser.js'),'utf8');
131
+ for(const token of ['safeNavigate','safeFilter','safeOpen','safeConfirm',
132
+ 'confirm-request','confirm-cancel','confirmation-prompt-missing',
133
+ 'cancel-mutated-persistent-data','FINORA.Storage.getAll(store)',
134
+ 'safe-action-vanished','editInvoice','editProduct','editContact',
135
+ 'editCheque','runFinancialDiagnostics','checkHolooMigrationReadiness']) {
136
+ assert.ok(audit.includes(token),'native action audit missing coverage contract: '+token);
137
+ }
138
+ assert.match(audit,/const confirmStores=\['users','companies','contacts','products'/);
139
+ assert.match(audit,/category !== 'open' && category !== 'confirm-request'/);
140
+ assert.match(audit,/\._togglePreInvoice\|_setStockFilter\|_clearFilters/);
141
+});
142
+
143
test('Q01: form labels are only associated within unambiguous modal groups', () => {
144
const modal=fs.readFileSync(path.join(root,'src','core','Modal.js'),'utf8');
145
const audit=fs.readFileSync(path.join(root,'tests','windows-vm-ui-interaction-audit-browser.js'),'utf8');