diff options
author | Ryan Leckey <ryan@launchbadge.com> | 2017-06-13 23:43:35 -0700 |
---|---|---|
committer | Ryan Leckey <ryan@launchbadge.com> | 2017-06-13 23:43:35 -0700 |
commit | 9a2e756075dce24e764c8c89e2d71703a69fd80a (patch) | |
tree | 52c1fcff16a0911eb9327ff876be5e2e92db6c1c /tests | |
parent | 04ad01390f68e7cc83de513e93fac18817801dbe (diff) |
Add (failing) test for File::with_name
Diffstat (limited to 'tests')
-rw-r--r-- | tests/file.rs | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/tests/file.rs b/tests/file.rs index a1b7506..4dba71f 100644 --- a/tests/file.rs +++ b/tests/file.rs @@ -20,3 +20,12 @@ fn test_file_required_not_found() { "configuration file \"tests/NoSettings\" not found" .to_string()); } + +#[test] +fn test_file_auto() { + let mut c = Config::default(); + c.merge(File::with_name("tests/Settings-production")).unwrap(); + + assert_eq!(c.get("debug").ok(), Some(false)); + assert_eq!(c.get("production").ok(), Some(true)); +} |