mirror of
https://github.com/gethomepage/homepage.git
synced 2026-05-18 19:40:58 +08:00
Fix: include tasks params for PBS widget (#6655)
This commit is contained in:
@@ -10,6 +10,7 @@ const widget = {
|
|||||||
},
|
},
|
||||||
"nodes/localhost/tasks": {
|
"nodes/localhost/tasks": {
|
||||||
endpoint: "nodes/localhost/tasks",
|
endpoint: "nodes/localhost/tasks",
|
||||||
|
params: ["errors", "limit", "since"],
|
||||||
},
|
},
|
||||||
"nodes/localhost/status": {
|
"nodes/localhost/status": {
|
||||||
endpoint: "nodes/localhost/status",
|
endpoint: "nodes/localhost/status",
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
import { describe, it } from "vitest";
|
import { describe, expect, it } from "vitest";
|
||||||
|
|
||||||
import { expectWidgetConfigShape } from "test-utils/widget-config";
|
import { expectWidgetConfigShape } from "test-utils/widget-config";
|
||||||
|
|
||||||
@@ -8,4 +8,8 @@ describe("proxmoxbackupserver widget config", () => {
|
|||||||
it("exports a valid widget config", () => {
|
it("exports a valid widget config", () => {
|
||||||
expectWidgetConfigShape(widget);
|
expectWidgetConfigShape(widget);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
it("requires failed task query params for the tasks endpoint", () => {
|
||||||
|
expect(widget.mappings["nodes/localhost/tasks"].params).toEqual(["errors", "limit", "since"]);
|
||||||
|
});
|
||||||
});
|
});
|
||||||
|
|||||||
Reference in New Issue
Block a user