Add a variant_name key to the WPT canvas test Jinja template
The Jinja template for WPT canvas tests is currently provided with a
variant_names list which stores the name of each variant dimensions.
This is useful to get the name of a specific dimension in a
multi-dimensional variant test, for instance in a 2d variant grid:
https://crsrc.org/c/third_party/blink/web_tests/external/wpt/html/canvas/tools/yaml-new/filters.yaml;l=620;drc=869e38fe2f8c29a863c92b775a3549a1adae37f8
Most variant tests however use a single dimension, so having to use a
variant_names list is cumbersome and can look strange to someone
unfamiliar with multi-dimensional variants (having to do
variant_names[0] to access the variant name is surprising).
To simplify test implementation, this CL adds a "variant_name" string
which stores a concatenation of all variant dimension names (e.g.
"variantA1.variantB1"). For tests with a single variant dimension,
variant_name is a shorthand for variant_names[0].
Bug: 340005429
Change-Id: Ic04db7dd687dc145e8622356ea958f905c375c64
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5597104
Reviewed-by: Andres Ricardo Perez andresrperez@chromium.org
Commit-Queue: Jean-Philippe Gravel jpgravel@chromium.org
Cr-Commit-Position: refs/heads/main@{#1310775}