mirror of
https://github.com/storytold/lightcraft.git
synced 2026-10-29 20:48:33 -06:00
crates/raw/tests/robust.rs only mutated DNGs. Add two small valid CR3 fixtures (a 4x4 lossless CRX and a 16x16 three-level C-RAW CRX) and a property that flips bytes in them or truncates them, then runs the existing exercise() helper (probe, embedded_preview, decode, develop and the colour transform) plus probe_info, the header-only description used on import: errors or clean decodes, never a panic. Unlike random TIFF-like bytes, a structurally valid file gets past the container walk, so the mutations land in the CRX marker walker and entropy readers. A fixture test asserts that both files decode as built, so the mutations hit live decode paths. Tests only; the existing DNG property keeps its 400 cases and the new one uses proptest's default (256, PROPTEST_CASES overrides it).