Skip to content
File

Blob: tests/client/components/editor/controllers/image/insert-popover.test.ts

typescript11 lines
1import { describe, expect, it } from "vitest";
2import { validateImageUrl } from "@/client/components/editor/controllers/image/validate-image-url";
3 
4describe("validateImageUrl", () => {
5 it("rejects insecure http image embeds before any network checks", async () => {
6 await expect(validateImageUrl("http://example.com/image.png")).rejects.toThrow(
7 "Image URLs must start with https://",
8 );
9 });
10});