Aman-Mittal commented on issue #691: URL: https://github.com/apache/fineract-backoffice-ui/issues/691#issuecomment-5970844979
Coverage for both halves has landed in #692, so whoever picks this up has a failing-on-fix harness rather than a blank page. In `e2e/loan-flows-non-admin-roles.spec.ts`: - `the disburser is offered the control, and the route refuses it — see #691` asserts `landsOn(...) === '/forbidden'` - `and the same route admits an UPDATE_LOAN holder the platform will refuse` asserts the route returns the form Each carries a message saying that a pass after the fix means the assertion needs inverting, so the spec fails loudly rather than quietly re-asserting today's behaviour: ``` 'the disbursement form admitted a DISBURSE_LOAN holder; if this now passes the route gate was fixed' 'the route refused an UPDATE_LOAN holder; if this now passes the gate was narrowed' ``` Both are preceded by a `platformAllows()` probe, so the platform's own answer is on record in the same test and a future reader does not have to re-derive it. One thing worth flagging for whoever fixes it: **`scripts/check-route-permissions.mjs` passes on this route today.** The route does declare a permission, so the check is satisfied — it has no way to know the declaration names the wrong code. If option (1) is taken, it may be worth teaching that script about per-command routes; otherwise the next one of these is just as invisible. Also note that #692 adds `data-testid="loan-disburse-action"`, which the button lacked. Any fix will want it: when `appRequiresPermission` refuses a control it replaces the accessible name with the reason, so a name-based locator cannot find the button in the state a permission test needs to assert on. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
