mirror of
https://github.com/outline/outline.git
synced 2026-11-22 14:01:41 +03:00
11 lines
363 B
TypeScript
11 lines
363 B
TypeScript
import { buildAttachment } from "@server/test/factories";
|
|
import Attachment from "./Attachment";
|
|
|
|
describe("#findByKey", () => {
|
|
it("should return the correct attachment given a key", async () => {
|
|
const attachment = await buildAttachment();
|
|
const found = await Attachment.findByKey(attachment.key);
|
|
expect(found?.id).toBe(attachment.id);
|
|
});
|
|
});
|