From cac77af9e26962bf189ebcc2eaa4e044bc09eda6 Mon Sep 17 00:00:00 2001 From: xuesong Date: Mon, 18 Oct 2021 19:57:12 +0800 Subject: [PATCH] fix(traits1): rename test functions to snake case (#854) Co-authored-by: zhangshaozhi --- exercises/advanced_errors/advanced_errs2.rs | 1 - exercises/traits/traits1.rs | 4 ++-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/exercises/advanced_errors/advanced_errs2.rs b/exercises/advanced_errors/advanced_errs2.rs index d9d44d06cb..54e669fdf6 100644 --- a/exercises/advanced_errors/advanced_errs2.rs +++ b/exercises/advanced_errors/advanced_errs2.rs @@ -64,7 +64,6 @@ impl Display for ParseClimateError { match self { NoCity => write!(f, "no city name"), ParseFloat(e) => write!(f, "error parsing temperature: {}", e), - _ => write!(f, "unhandled error!"), } } } diff --git a/exercises/traits/traits1.rs b/exercises/traits/traits1.rs index 2ef9e11bba..15e08f243f 100644 --- a/exercises/traits/traits1.rs +++ b/exercises/traits/traits1.rs @@ -29,12 +29,12 @@ mod tests { use super::*; #[test] - fn is_FooBar() { + fn is_foo_bar() { assert_eq!(String::from("Foo").append_bar(), String::from("FooBar")); } #[test] - fn is_BarBar() { + fn is_bar_bar() { assert_eq!( String::from("").append_bar().append_bar(), String::from("BarBar")