fix: finish 2.9.0 plugin moves and get every check green

This commit is contained in:
LukeGus committed 2026-09-24 23:35:18 -05:00
1 parent 8c1e02af89
commit 6489b62ece
335 files changed
+29878 -17749

No files matched your search

@@ -0,0 +1,25 @@
import { describe, expect, it } from "vitest";
import { validateCaSettings } from "../../src/backend/client.js";
describe("validateCaSettings", () => {
it("accepts an https URL and a SHA-256 fingerprint", () => {
expect(
validateCaSettings({
caUrl: "https://ca.example.com:9000/",
fingerprint: "ab".repeat(32),
}),
).toEqual({});
});
it("rejects a plain http URL and a short fingerprint at save time", () => {
const errors = validateCaSettings({
caUrl: "http://ca.example.com",
fingerprint: "abcd",
});
expect(Object.keys(errors).sort()).toEqual(["caUrl", "fingerprint"]);
});
it("leaves empty fields to the not-configured message", () => {
expect(validateCaSettings({ caUrl: "", fingerprint: " " })).toEqual({});
});
});