Skip to content

Commit 263d59c

Browse files
author
Max Christoph
committed
add test for non string map keys for ron format
1 parent aebee22 commit 263d59c

File tree

2 files changed

+11
-1
lines changed

2 files changed

+11
-1
lines changed

tests/Settings.ron

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,5 +18,13 @@
1818
}
1919
),
2020
FOO: "FOO should be overridden",
21-
bar: "I am bar"
21+
bar: "I am bar",
22+
map: {
23+
1: '1',
24+
2: '4',
25+
3: '9',
26+
4: '1',
27+
5: '2',
28+
6: '3',
29+
},
2230
)

tests/file_ron.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
#![cfg(feature = "ron")]
22

3+
use std::collections::HashMap;
34
use serde_derive::Deserialize;
45

56
use std::path::PathBuf;
@@ -27,6 +28,7 @@ struct Settings {
2728
place: Place,
2829
#[serde(rename = "arr")]
2930
elements: Vec<String>,
31+
map: HashMap<u8, char>,
3032
}
3133

3234
fn make() -> Config {

0 commit comments

Comments
 (0)