diff options
author | David Orchard <if_coding@fastmail.com> | 2021-07-28 22:49:48 -0700 |
---|---|---|
committer | David Orchard <if_coding@fastmail.com> | 2021-08-15 10:31:10 -0700 |
commit | 62c84297e5340d717d89c5c0b36ed86dd5ad9d2f (patch) | |
tree | e3062f57dfb10b921267aeeed5df6b42d93a4657 /tests/file_json.rs | |
parent | 74a0a809f642e2d212752c9ccb767d987c42302e (diff) |
Create test cases to demonstrate lossy map order
Diffstat (limited to 'tests/file_json.rs')
-rw-r--r-- | tests/file_json.rs | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/tests/file_json.rs b/tests/file_json.rs index 4563e42..4e5edbc 100644 --- a/tests/file_json.rs +++ b/tests/file_json.rs @@ -60,8 +60,15 @@ fn test_file() { assert_eq!(s.elements.len(), 10); assert_eq!(s.elements[3], "4".to_string()); assert_eq!( - s.place.creator["name"].clone().into_string().unwrap(), - "John Smith".to_string() + s.place + .creator + .into_iter() + .collect::<Vec<(String, config::Value)>>(), + vec![ + ("name".to_string(), "John Smith".into()), + ("username".into(), "jsmith".into()), + ("email".into(), "jsmith@localhost".into()), + ] ); } |