diff --git a/extensions/scarb-doc/src/main.rs b/extensions/scarb-doc/src/main.rs index 7cf7dbafb..8dde04637 100644 --- a/extensions/scarb-doc/src/main.rs +++ b/extensions/scarb-doc/src/main.rs @@ -65,7 +65,8 @@ fn main_inner() -> Result<()> { OutputFormat::Json => { let versioned_json_output = VersionedJsonOutput::new(package_information_map); let output = serde_json::to_string_pretty(&versioned_json_output) - .expect("failed to serialize information about crates"); + .expect("failed to serialize information about crates") + + "\n"; let output_path = output_dir.join("output.json"); fs::write(output_path, output) diff --git a/extensions/scarb-doc/tests/data/json_output_test_data.json b/extensions/scarb-doc/tests/data/json_output_test_data.json index 5d1c4e451..c0f58e917 100644 --- a/extensions/scarb-doc/tests/data/json_output_test_data.json +++ b/extensions/scarb-doc/tests/data/json_output_test_data.json @@ -278,4 +278,4 @@ } } } -} \ No newline at end of file +}