summaryrefslogtreecommitdiffstats
path: root/tests/errors.rs
diff options
context:
space:
mode:
authorRyan Leckey <leckey.ryan@gmail.com>2017-07-30 13:20:36 -0700
committerRyan Leckey <leckey.ryan@gmail.com>2017-07-30 13:20:36 -0700
commit14224be23dc2f253a240b85214927d97e1160669 (patch)
tree6f5b02b26aef5cf37bb14f32b9048165b67109ce /tests/errors.rs
parent71f4b182d1e56febda64bd620ae0e0f65de333cd (diff)
Remove ConfigResult; close #36
Diffstat (limited to 'tests/errors.rs')
-rw-r--r--tests/errors.rs21
1 files changed, 14 insertions, 7 deletions
diff --git a/tests/errors.rs b/tests/errors.rs
index 835ead1..77a58ab 100644
--- a/tests/errors.rs
+++ b/tests/errors.rs
@@ -16,8 +16,10 @@ fn test_error_parse() {
let res = c.merge(File::new("tests/Settings-invalid", FileFormat::Toml));
assert!(res.is_err());
- assert_eq!(res.unwrap_err().to_string(),
- "invalid number at line 2 in tests/Settings-invalid.toml".to_string());
+ assert_eq!(
+ res.unwrap_err().to_string(),
+ "invalid number at line 2 in tests/Settings-invalid.toml".to_string()
+ );
}
#[test]
@@ -27,9 +29,12 @@ fn test_error_type() {
let res = c.get::<bool>("boolean_s_parse");
assert!(res.is_err());
- assert_eq!(res.unwrap_err().to_string(),
- "invalid type: string \"fals\", expected a boolean for key `boolean_s_parse` in tests/Settings.toml"
- .to_string());
+ assert_eq!(
+ res.unwrap_err().to_string(),
+ "invalid type: string \"fals\", expected a boolean for key \
+ `boolean_s_parse` in tests/Settings.toml"
+ .to_string()
+ );
}
#[test]
@@ -40,6 +45,8 @@ fn test_error_type_detached() {
let res = value.try_into::<bool>();
assert!(res.is_err());
- assert_eq!(res.unwrap_err().to_string(),
- "invalid type: string \"fals\", expected a boolean".to_string());
+ assert_eq!(
+ res.unwrap_err().to_string(),
+ "invalid type: string \"fals\", expected a boolean".to_string()
+ );
}