mirror of
https://github.com/rcourtman/Pulse.git
synced 2026-10-27 05:57:27 +00:00
Match exact read routes in stale-memory browser proof
Keep guest-operation and mutation refusals, but match operation path segments rather than the run prefix of the read-only runtime-capabilities route. Bind the empty History fixture to the production metrics-store/history route. Preserve both prior browser failures and the original product assertions. Change-source: pulse-maintainer
This commit is contained in:
@@ -78,9 +78,12 @@ const settle = (page) =>
|
||||
if (!url.pathname.startsWith('/api/')) return route.continue();
|
||||
record.requests.push({ path: url.pathname, method: request.method() });
|
||||
assert.equal(request.method(), 'GET', 'no mutations');
|
||||
assert(!/diagnostics|\/run|guest-agent|qemu/.test(url.pathname), 'no guest operations');
|
||||
assert(
|
||||
!/\/(?:diagnostics|run|run-command|guest-agent|qemu)(?:\/|$)/.test(url.pathname),
|
||||
`no guest operations: ${url.pathname}`,
|
||||
);
|
||||
let body = { success: true, data: [], alerts: [], anomalies: [], config: null };
|
||||
if (url.pathname.includes('/charts/'))
|
||||
if (url.pathname === '/api/metrics-store/history')
|
||||
body = {
|
||||
resourceType: 'vm',
|
||||
resourceId: url.searchParams.get('resourceId') || 'fixture:pve1:101',
|
||||
|
||||
Reference in New Issue
Block a user