()
| 212 | |
| 213 | #[test] |
| 214 | fn test_parse_bounded_string() { |
| 215 | let msg_content = r#" |
| 216 | string<=255 type_name |
| 217 | Field[] fields |
| 218 | "#; |
| 219 | let path = PathBuf::from("IndividualTypeDescription.msg"); |
| 220 | |
| 221 | let msg = parse_msg_string(msg_content, "type_description_interfaces", &path).unwrap(); |
| 222 | |
| 223 | assert_eq!(msg.fields.len(), 2); |
| 224 | assert_eq!(msg.fields[0].name, "type_name"); |
| 225 | assert_eq!(msg.fields[0].field_type.base_type, "string"); |
| 226 | assert_eq!(msg.fields[1].name, "fields"); |
| 227 | } |
| 228 | |
| 229 | #[test] |
| 230 | fn test_parse_bounded_string_with_constants() { |
nothing calls this directly
no test coverage detected