aboutsummaryrefslogtreecommitdiff
path: root/crates/test_utils/src
diff options
context:
space:
mode:
Diffstat (limited to 'crates/test_utils/src')
-rw-r--r--crates/test_utils/src/lib.rs5
1 files changed, 4 insertions, 1 deletions
diff --git a/crates/test_utils/src/lib.rs b/crates/test_utils/src/lib.rs
index 097a54139..dd582c77c 100644
--- a/crates/test_utils/src/lib.rs
+++ b/crates/test_utils/src/lib.rs
@@ -18,7 +18,7 @@ use std::{
18}; 18};
19 19
20use profile::StopWatch; 20use profile::StopWatch;
21use stdx::lines_with_ends; 21use stdx::{is_ci, lines_with_ends};
22use text_size::{TextRange, TextSize}; 22use text_size::{TextRange, TextSize};
23 23
24pub use dissimilar::diff as __diff; 24pub use dissimilar::diff as __diff;
@@ -376,6 +376,9 @@ pub fn try_ensure_file_contents(file: &Path, contents: &str) -> Result<(), ()> {
376 "\n\x1b[31;1merror\x1b[0m: {} was not up-to-date, updating\n", 376 "\n\x1b[31;1merror\x1b[0m: {} was not up-to-date, updating\n",
377 display_path.display() 377 display_path.display()
378 ); 378 );
379 if is_ci() {
380 eprintln!("\n NOTE: run `cargo test` locally and commit the updated files\n");
381 }
379 if let Some(parent) = file.parent() { 382 if let Some(parent) = file.parent() {
380 let _ = std::fs::create_dir_all(parent); 383 let _ = std::fs::create_dir_all(parent);
381 } 384 }