From 5c44349a894b0ce0a7108f070ec7be72827b5f2e Mon Sep 17 00:00:00 2001 From: William Dunn Date: Wed, 11 Nov 2026 22:03:19 -0500 Subject: [PATCH] craft-esign apply rustfmt to the new tests Wraps a few lines fmt would otherwise reject on the next check. --- crates/ui/src/esign/coderabbit_repro.rs | 7 ++++++- crates/ui/src/esign/mod.rs | 18 ++++++++++-------- 2 files changed, 16 insertions(+), 9 deletions(-) diff --git a/crates/ui/src/esign/coderabbit_repro.rs b/crates/ui/src/esign/coderabbit_repro.rs index 98414fb75..88d875d29 100644 --- a/crates/ui/src/esign/coderabbit_repro.rs +++ b/crates/ui/src/esign/coderabbit_repro.rs @@ -45,7 +45,12 @@ fn create_reply_for_a_request_taken_before_reopening_does_not_install_in_the_new // The dialog moves on before the application gets around to submitting // what it already took. dialog.open("doc-B".into(), "B.pdf".into(), None, who("alice")); - dialog.submit_request(Request::Create { draft: Box::new(out.draft), document: b"A bytes".to_vec(), idempotency_key: out.idempotency_key, send: true }); + dialog.submit_request(Request::Create { + draft: Box::new(out.draft), + document: b"A bytes".to_vec(), + idempotency_key: out.idempotency_key, + send: true, + }); let (_, create) = hold.take(|r| matches!(r, Request::Create { .. })); create.answer(Answer::Created(envelope_for("doc-A", "alice"))); diff --git a/crates/ui/src/esign/mod.rs b/crates/ui/src/esign/mod.rs index 9bf9d95b6..18ad4f608 100644 --- a/crates/ui/src/esign/mod.rs +++ b/crates/ui/src/esign/mod.rs @@ -836,12 +836,8 @@ mod tests { #[test] fn compose_form_shows_sign_in_message_when_not_linked() { - let mut dialog = EsignDialog { - capabilities: Some(vec![EsignCapability::Envelopes]), - document_title: "A.pdf".into(), - linked: false, - ..Default::default() - }; + let mut dialog = + EsignDialog { capabilities: Some(vec![EsignCapability::Envelopes]), document_title: "A.pdf".into(), linked: false, ..Default::default() }; let ctx = Context::default(); let mut full = ctx.run_ui(egui::RawInput::default(), |ui| dialog.ui(ui)); full.textures_delta.clear(); @@ -860,8 +856,14 @@ mod tests { #[test] fn add_contact_rejects_a_contact_with_no_email() { let mut dialog = EsignDialog::default(); - let contact = - Contact { id: "share-id-123".into(), target: craft_cloud::ShareTarget::User("share-id-123".into()), name: "Mallory".into(), email: None, avatar: None, is_group: false }; + let contact = Contact { + id: "share-id-123".into(), + target: craft_cloud::ShareTarget::User("share-id-123".into()), + name: "Mallory".into(), + email: None, + avatar: None, + is_group: false, + }; dialog.add_contact(contact); assert!(dialog.recipients.is_empty(), "a contact with no email became a recipient: {:?}", dialog.recipients); assert_eq!(dialog.error.as_deref(), Some(dialog.labels.contact_missing_email.as_str()));