v2 / vlib / x / json2 / tests / decode_map_of_map_test.v
13 lines · 11 sloc · 249 bytes · 2d33a7f2819dd5fc1f4aa3b3ca0bcc660810d7af
Raw
1import x.json2
2
3struct CrossVerifyResult {
4 confusion_matrix_map map[string]map[string]f64
5}
6
7fn test_main() {
8 x := json2.decode[CrossVerifyResult]('') or {
9 assert err.msg().contains('1:1: Invalid json: empty string')
10 return
11 }
12 assert false
13}
14