From 2ad72dcbd14112862a3c3b2793896411cbcf5ce1 Mon Sep 17 00:00:00 2001 From: Grzegorz Martens Date: Sat, 31 Oct 2026 17:32:10 +0100 Subject: [PATCH] M11: the JPEG test has its doc comment back The JBIG2 test went in between the two. Co-Authored-By: Claude Opus 5.5 Claude-Session: https://claude.ai/code/session_01AmsdeUCdTaD72jkDw2pJKY --- crates/optimize/src/images.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/crates/optimize/src/images.rs b/crates/optimize/src/images.rs index cdd3c89d91..b25e8484c9 100644 --- a/crates/optimize/src/images.rs +++ b/crates/optimize/src/images.rs @@ -1309,7 +1309,6 @@ mod dimension_tests { assert_eq!(pixels(&Document::new_empty(), &stream, 1), Some(vec![1, 2, 3, 4])); } - /// A JPEG larger than its dictionary says is refused from its header, before its pixels are decoded. /// JBIG2 alone, with Group 4 asked for, is decoded only to be resampled. A cost guard: dropped, /// no output changes, and an ordinary scan pays a quarter of a second a page for nothing. Behind /// another filter it can still be stored again, as Group 4 can. @@ -1340,6 +1339,7 @@ mod dimension_tests { assert!(decoded(&alone, &jbig2) > 0, "stored as JBIG2 its symbols may come out smaller"); } + /// A JPEG larger than its dictionary says is refused from its header, before its pixels are decoded. #[test] fn a_jpeg_of_another_size_than_its_dictionary_is_not_decoded() { let data = jpeg(&vec![128; 1000 * 1000], 1, 1000, 1000, 50).unwrap_or_default();