From b10d44d0c0dcfd5cf0a33a7a77b6b2bb9f303f23 Mon Sep 17 00:00:00 2001 From: Ivan Ukhov Date: Fri, 5 Jun 2015 15:00:30 -0400 Subject: [PATCH] Change Display for ResultCode --- src/result.rs | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/src/result.rs b/src/result.rs index 9f52b38..f84affd 100644 --- a/src/result.rs +++ b/src/result.rs @@ -62,8 +62,8 @@ declare!( impl Display for ResultCode { fn fmt(&self, formatter: &mut Formatter) -> fmt::Result { match *self { - ResultCode::Unknown => write!(formatter, "an unknown SQLite code"), - _ => write!(formatter, "SQLite code {}", *self as isize), + ResultCode::Unknown => write!(formatter, "an unknown SQLite result code"), + _ => write!(formatter, "SQLite result code {}", *self as isize), } } } @@ -75,7 +75,9 @@ mod tests { #[test] fn fmt() { - assert_eq!(format!("{}", ResultCode::OK), String::from("SQLite code 0")); - assert_eq!(format!("{}", code_from_raw(777)), String::from("an unknown SQLite code")); + assert_eq!(format!("{}", ResultCode::OK), + String::from("SQLite result code 0")); + assert_eq!(format!("{}", code_from_raw(777)), + String::from("an unknown SQLite result code")); } }