perf(web): pause hidden live polling
This commit is contained in:
@@ -28,6 +28,10 @@ test('rapid viewport changes retain one workspace payload and avoid duplicate fl
|
||||
});
|
||||
|
||||
await waitFor(() => expect(monitorWorkspace).toHaveBeenCalledTimes(1));
|
||||
const workspaceQuery = client.getQueryCache().findAll({ queryKey: ['monitor', 'workspace'] })[0];
|
||||
const liveOptions = workspaceQuery?.options as { refetchIntervalInBackground?: boolean; refetchOnWindowFocus?: boolean };
|
||||
expect(liveOptions.refetchIntervalInBackground).toBe(false);
|
||||
expect(liveOptions.refetchOnWindowFocus).toBe(true);
|
||||
expect(monitorSummary).not.toHaveBeenCalled();
|
||||
expect(vehicleRealtime).not.toHaveBeenCalled();
|
||||
for (let index = 1; index <= 8; index += 1) {
|
||||
|
||||
Reference in New Issue
Block a user