Reorganize repo structure and standards references

This commit is contained in:
david committed 2026-06-29 05:03:42 +02:00
1 parent 3cb93a81be
commit be2054274d
5885 files changed
+2588 -195

No files matched your search

@@ -0,0 +1,22 @@
import { describe, expect, it } from "vitest";
import { readLiveReloadUrl } from "../capacitor.config.js";
describe("readLiveReloadUrl", () => {
it("returns undefined when live reload is not configured", () => {
expect(readLiveReloadUrl(undefined)).toBeUndefined();
expect(readLiveReloadUrl(" ")).toBeUndefined();
});
it("preserves valid http and https URLs", () => {
expect(readLiveReloadUrl(" http://10.0.2.2:3000 ")).toBe("http://10.0.2.2:3000");
expect(readLiveReloadUrl("https://staging.example.test")).toBe("https://staging.example.test");
});
it("rejects unsupported protocols", () => {
expect(() => readLiveReloadUrl("ftp://example.test")).toThrow(/http/);
});
it("rejects relative URLs", () => {
expect(() => readLiveReloadUrl("localhost:3000")).toThrow(/absolute/);
});
});