MCPcopy Create free account
hub / github.com/heygen-com/hyperframes / expectOne

Function expectOne

packages/cli/src/utils/motionAudit.test.ts:13–18  ·  view source on GitHub ↗
(issues: LayoutIssue[])

Source from the content-addressed store, hash-verified

11const CANVAS = { width: 1920, height: 1080 };
12
13function expectOne(issues: LayoutIssue[]): LayoutIssue {
14 expect(issues).toHaveLength(1);
15 const issue = issues[0];
16 if (!issue) throw new Error("expected exactly one issue");
17 return issue;
18}
19
20function rect(left: number, top: number, width: number, height: number) {
21 return { left, top, right: left + width, bottom: top + height, width, height };

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected