benchtests: make compare_strings.py accept string as attribute value
authorSu Lifan <su-lifan@linux.alibaba.com>
Fri, 25 Feb 2022 08:58:07 +0000 (16:58 +0800)
committerSiddhesh Poyarekar <siddhesh@sourceware.org>
Tue, 8 Mar 2022 14:12:52 +0000 (19:42 +0530)
Commit ac759b1fbf28a82d99afde9046f8b72c7cba5dae added attribute
"overlap" to bench-memmove-walk, whose value is a string. This change
makes compare_strings.py fail since benchout_strings.schema.json
requires the values of attributes to be number.

This patch relaxes such constraint.
Reviewed-by: Siddhesh Poyarekar <siddhesh@sourceware.org>
benchtests/scripts/benchout_strings.schema.json

index 7c9a671..bfd9b4e 100644 (file)
                    "items": {"type": "number"}
                    }
                 },
-                "additionalProperties": {"type": "number"},
+                "additionalProperties": {
+                  "oneOf": [
+                    { "type": "number" },
+                    { "type": "string" }
+                  ]
+                },
                 "minProperties": 2
              }
            }