mirror of
https://github.com/Matysh/houseplan-card
synced 2026-10-02 12:49:56 +00:00
test: await warm navigation request before checking its authority (#762)
Issue: #762 User-Visible: no
This commit is contained in:
@@ -12,7 +12,11 @@ const res = await page.evaluate(async () => {
|
||||
c._setMode = (...args) => { resumedThroughSetMode += 1; return realSetMode(...args); };
|
||||
c._pendingNavMode = 'devices';
|
||||
c._serverCanWrite = true;
|
||||
out.pendingModeUsesTransitionAuthority = c._resumePendingNavMode() === true
|
||||
const pendingAccepted = c._resumePendingNavMode();
|
||||
// Both loaded and delayed runtimes now cross the same async request boundary.
|
||||
// Observe the next rendered frame, still requiring exactly one real authority call.
|
||||
await new Promise((resolve) => requestAnimationFrame(resolve)); await c.updateComplete;
|
||||
out.pendingModeUsesTransitionAuthority = pendingAccepted === true
|
||||
&& resumedThroughSetMode === 1 && c._mode === 'devices' && c._pendingNavMode == null;
|
||||
delete c._setMode;
|
||||
c._setMode('view', false); await c.updateComplete;
|
||||
|
||||
@@ -17,8 +17,8 @@ to prove that the Node witness actually kills it.
|
||||
| Paint, cascade and layer composition | 26 | The invariant depends on computed CSS, SVG paint, clipping, stacking or pixels produced by Chromium. |
|
||||
| Pointer geometry and trusted interaction | 45 | The invariant depends on hit testing, pointer capture, touch/keyboard dispatch or live DOM geometry. |
|
||||
| Responsive DOM layout | 38 | The invariant depends on measured element boxes, responsive breakpoints, native/HA dialog shells or focusable target size. |
|
||||
| Custom-element and HA browser lifecycle | 96 | The invariant crosses Lit/custom-element lifecycle, browser storage/events, lazy loading or a complete HA-card state transition. |
|
||||
| **Total** | **213 / 200** | Above the guideline `mutation-gate --check` warns rather than fails (#699); each guard above it is held by its own reason in this inventory and its `because`. |
|
||||
| Custom-element and HA browser lifecycle | 97 | The invariant crosses Lit/custom-element lifecycle, browser storage/events, lazy loading or a complete HA-card state transition. |
|
||||
| **Total** | **214 / 200** | Above the guideline `mutation-gate --check` warns rather than fails (#699); each guard above it is held by its own reason in this inventory and its `because`. |
|
||||
|
||||
## Measured effect
|
||||
|
||||
|
||||
Reference in New Issue
Block a user