diff --git a/git-cliff-core/tests/integration_test.rs b/git-cliff-core/tests/integration_test.rs index 2676d21c77..e2f99b0d97 100644 --- a/git-cliff-core/tests/integration_test.rs +++ b/git-cliff-core/tests/integration_test.rs @@ -266,6 +266,11 @@ fn generate_changelog() -> Result<()> { let template = Template::new("test", changelog_config.body.unwrap(), false)?; writeln!(out, "{}", changelog_config.header.unwrap()).unwrap(); + let text_processors = [TextProcessor { + pattern: Regex::new("").unwrap(), + replace: Some(String::from("2023")), + replace_command: None, + }]; for release in releases { write!( out, @@ -273,11 +278,7 @@ fn generate_changelog() -> Result<()> { template.render( &release, Option::>::None.as_ref(), - &[TextProcessor { - pattern: Regex::new("").unwrap(), - replace: Some(String::from("2023")), - replace_command: None, - }] + &text_processors )? ) .unwrap();