mirror of
https://github.com/outline/outline.git
synced 2026-04-29 05:59:33 -05:00
67b1fe5514
Co-authored-by: Tom Moor <tom.moor@gmail.com>
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);
|
|
});
|
|
});
|