Merge custom option test fix into dnd kit
This commit is contained in:
2 files changed
+11
-12
No files matched your search
@@ -71,17 +71,16 @@ describe("lean Custom Widget options", () => {
|
|||||||
});
|
});
|
||||||
|
|
||||||
it("replaces stale values with current defaults", () => {
|
it("replaces stale values with current defaults", () => {
|
||||||
const options = customWidgetDefinitionSchema.parse({
|
const options = {
|
||||||
$schema: "homarr-custom-widget-v2",
|
limit: customWidgetOptionSchema.parse({
|
||||||
name: "Updated options",
|
label: "Limit",
|
||||||
sources: {},
|
control: "slider",
|
||||||
requests: {},
|
default: 5,
|
||||||
options: {
|
min: 1,
|
||||||
limit: { label: "Limit", control: "slider", default: 5, min: 1, max: 10 },
|
max: 10,
|
||||||
label: { label: "Label", control: "text", default: "Default" },
|
}),
|
||||||
},
|
label: customWidgetOptionSchema.parse({ label: "Label", control: "text", default: "Default" }),
|
||||||
template: "<Text>{options.limit}</Text>",
|
};
|
||||||
}).options;
|
|
||||||
|
|
||||||
const normalized = normalizeCustomWidgetOptions(options, {
|
const normalized = normalizeCustomWidgetOptions(options, {
|
||||||
limit: "5",
|
limit: "5",
|
||||||
|
|||||||
@@ -6,7 +6,7 @@ import { integrationDefs } from "../integration";
|
|||||||
|
|
||||||
describe("Icon url's of integrations should be valid and return 200", () => {
|
describe("Icon url's of integrations should be valid and return 200", () => {
|
||||||
objectEntries(integrationDefs).forEach(([integration, { iconUrl }]) => {
|
objectEntries(integrationDefs).forEach(([integration, { iconUrl }]) => {
|
||||||
it.concurrent(`should return 200 for ${integration}`, async () => {
|
it(`should return 200 for ${integration}`, { concurrent: true, retry: 2, timeout: 15_000 }, async () => {
|
||||||
const res = await fetch(iconUrl);
|
const res = await fetch(iconUrl);
|
||||||
expect(res.status).toBe(200);
|
expect(res.status).toBe(200);
|
||||||
});
|
});
|
||||||
|
|||||||
Reference in new issue
Block a user