diff --git a/crates/engine/src/tests.rs b/crates/engine/src/tests.rs index 95ace8c2d..d8a680880 100644 --- a/crates/engine/src/tests.rs +++ b/crates/engine/src/tests.rs @@ -7101,6 +7101,8 @@ fn exporting_office_keeps_dotted_leader_entries_as_paragraphs() { assert!(positions.windows(2).all(|pair| pair[0] < pair[1]), "reading order: {html}"); } +/// A date typed in another of an XFA date field's edit patterns is kept in its first: yymmdd and +/// yyyymd are rewritten as yyyymmdd, a date none of them reads is refused, and the data holds the date. #[test] fn a_date_typed_by_another_of_an_xfa_fields_edit_patterns_is_kept_in_its_first() { let mut s = Session::new(); diff --git a/crates/xfa/src/tests.rs b/crates/xfa/src/tests.rs index dbae4ef91..87875211f 100644 --- a/crates/xfa/src/tests.rs +++ b/crates/xfa/src/tests.rs @@ -2658,6 +2658,9 @@ fn trailing_spaces_do_not_shift_centered_or_right_aligned_text() { assert!((left_edge("right", "TITLE ") - (36.0 + w - ink)).abs() < 1e-6); } +/// `typed_date` rewrites a date typed by another of a field's edit-picture patterns in the first +/// one, and leaves alone a date the first pattern reads, text no pattern reads, a field with one +/// pattern and a field that isn't a date. #[test] fn a_date_typed_by_another_of_its_edit_pictures_patterns_is_written_in_the_first() { let (tpl, _) = crate::parse(&crate::fixtures::date_alternatives_template()).unwrap();