From 8a82f6336a7c9e520cbda2e82c524b0bf7c5c06a Mon Sep 17 00:00:00 2001 From: Ben Armstead Date: Tue, 24 Aug 2021 08:48:24 +0100 Subject: [PATCH] Format with cargo correctly --- src/renderer/html_handlebars/hbs_renderer.rs | 7 ++----- tests/rendered_output.rs | 8 ++++++-- 2 files changed, 8 insertions(+), 7 deletions(-) diff --git a/src/renderer/html_handlebars/hbs_renderer.rs b/src/renderer/html_handlebars/hbs_renderer.rs index 52abea51..e8da5b4a 100644 --- a/src/renderer/html_handlebars/hbs_renderer.rs +++ b/src/renderer/html_handlebars/hbs_renderer.rs @@ -54,11 +54,8 @@ impl HtmlHandlebars { let content = ch.content.clone(); let content = utils::render_markdown(&content, ctx.html_config.curly_quotes); - let fixed_content = utils::render_markdown_with_path( - &ch.content, - ctx.html_config.curly_quotes, - Some(path), - ); + let fixed_content = + utils::render_markdown_with_path(&ch.content, ctx.html_config.curly_quotes, Some(path)); if !ctx.is_index { // Add page break between chapters // See https://developer.mozilla.org/en-US/docs/Web/CSS/break-before and https://developer.mozilla.org/en-US/docs/Web/CSS/page-break-before diff --git a/tests/rendered_output.rs b/tests/rendered_output.rs index 3eae6c3f..b25f6152 100644 --- a/tests/rendered_output.rs +++ b/tests/rendered_output.rs @@ -560,7 +560,9 @@ fn edit_url_has_default_src_dir_edit_url() { let index_html = temp.path().join("book").join("index.html"); assert_contains_strings( index_html, - &[r#"href="https://github.com/rust-lang/mdBook/edit/master/guide/src/README.md" title="Suggest an edit""#], + &[ + r#"href="https://github.com/rust-lang/mdBook/edit/master/guide/src/README.md" title="Suggest an edit""#, + ], ); } @@ -584,7 +586,9 @@ fn edit_url_has_configured_src_dir_edit_url() { let index_html = temp.path().join("book").join("index.html"); assert_contains_strings( index_html, - &[r#"href="https://github.com/rust-lang/mdBook/edit/master/guide/src2/README.md" title="Suggest an edit""#], + &[ + r#"href="https://github.com/rust-lang/mdBook/edit/master/guide/src2/README.md" title="Suggest an edit""#, + ], ); }