1 parent 98596d3 commit a16b766Copy full SHA for a16b766
1 file changed
src/property.rs
@@ -543,4 +543,18 @@ mod tests {
543
assert_eq!(result[0].condition, "id > 5");
544
assert_eq!(result[1].condition, "id < 3");
545
}
546
+
547
+ #[test]
548
+ fn test_property_enum_value_from_odd_elements() {
549
+ let source = vec!["HIGH".to_string(), "red".to_string(), "orphan".to_string()];
550
+ let result = PropertyEnumValue::from(source);
551
+ assert_eq!(result.len(), 1, "Odd trailing element should be ignored without panic");
552
+ }
553
554
555
+ fn test_property_cond_format_from_odd_elements() {
556
+ let source = vec!["id > 5".to_string(), "red".to_string(), "orphan".to_string()];
557
+ let result = PropertyCondFormat::from(source);
558
559
560
0 commit comments