aboutsummaryrefslogtreecommitdiff
path: root/crates/test_utils
diff options
context:
space:
mode:
Diffstat (limited to 'crates/test_utils')
-rw-r--r--crates/test_utils/src/lib.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/crates/test_utils/src/lib.rs b/crates/test_utils/src/lib.rs
index 7f55779cf..8bb3b3937 100644
--- a/crates/test_utils/src/lib.rs
+++ b/crates/test_utils/src/lib.rs
@@ -318,7 +318,7 @@ pub fn project_dir() -> PathBuf {
318/// so this should always be correct. 318/// so this should always be correct.
319pub fn read_text(path: &Path) -> String { 319pub fn read_text(path: &Path) -> String {
320 fs::read_to_string(path) 320 fs::read_to_string(path)
321 .expect(&format!("File at {:?} should be valid", path)) 321 .unwrap_or_else(|_| panic!("File at {:?} should be valid", path))
322 .replace("\r\n", "\n") 322 .replace("\r\n", "\n")
323} 323}
324 324