perf: reduce widget and runtime overhead
This commit is contained in:
1 parent
5a7607ddf7
commit
14c7e58e17
33 files changed
+779
-339
No files matched your search
@@ -148,4 +148,23 @@ describe("widget manifest promise stability", () => {
|
||||
[...expectedByQueryKey.values()].map(serializePolicy).toSorted(),
|
||||
);
|
||||
});
|
||||
|
||||
it("does not poll integration handlers faster than their cache can refresh", async () => {
|
||||
const definitions = await loadAllWidgetDefinitions();
|
||||
const cachedWidgetKinds = [
|
||||
"dnsHoleControls",
|
||||
"dnsHoleSummary",
|
||||
"downloads",
|
||||
"firewall",
|
||||
"healthMonitoring",
|
||||
"mediaServer",
|
||||
"systemDisks",
|
||||
"systemResources",
|
||||
"tracearr",
|
||||
] as const;
|
||||
|
||||
for (const kind of cachedWidgetKinds) {
|
||||
expect(definitions.get(kind)?.refetchInterval).toBe(10);
|
||||
}
|
||||
});
|
||||
});
|
||||
Reference in new issue
Block a user