Skip to content

Test coverage: canvas stub yields empty masks; hook untested #2

Description

@quitequinn

The happy-dom canvas stub returns all-zero getImageData, so build() produces an empty MASK → distanceInside/orientation/dome-shade/buildStitchList/buildSewRows only ever run in their degenerate empty case; the BFS sew ordering is never validated on real geometry. measureText also lacks actualBoundingBox*, so the fit-to-width height branch never runs. Also useThreadText (create-once + update + setText + ResizeObserver + cleanup) has no test. Suggested: a stub that paints a non-trivial alpha mask, plus hook tests (React Testing Library is already a devDep). (User did not request tests; tracking only.)

Severity: Major (test coverage)

Metadata

Metadata

Assignees

No one assigned

    Labels

    reviewPanel review finding

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions