diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-05-15 03:35:49 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-05-15 03:35:49 +0000 |
commit | d8bbc7858622b6d9c278469aab701ca0b609cddf (patch) | |
tree | eff41dc61d9f714852212739e6b3738b82a2af87 /testing/web-platform/tests/html/canvas/tools/templates/testharness_offscreen.html | |
parent | Releasing progress-linux version 125.0.3-1~progress7.99u1. (diff) | |
download | firefox-d8bbc7858622b6d9c278469aab701ca0b609cddf.tar.xz firefox-d8bbc7858622b6d9c278469aab701ca0b609cddf.zip |
Merging upstream version 126.0.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to '')
-rw-r--r-- | testing/web-platform/tests/html/canvas/tools/templates/testharness_offscreen.html | 18 |
1 files changed, 12 insertions, 6 deletions
diff --git a/testing/web-platform/tests/html/canvas/tools/templates/testharness_offscreen.html b/testing/web-platform/tests/html/canvas/tools/templates/testharness_offscreen.html index 8ebbff77a6..68147680e1 100644 --- a/testing/web-platform/tests/html/canvas/tools/templates/testharness_offscreen.html +++ b/testing/web-platform/tests/html/canvas/tools/templates/testharness_offscreen.html @@ -15,6 +15,11 @@ {#- Promise vs. async test header: +#} {% if test_type == 'promise' %} promise_test(async t => { + +{% elif test_type == 'async' %} +async_test(t => { +{% elif test_type == 'sync' %} +test(t => { {% else %} var t = async_test("{{ desc | double_quote_escape }}"); var t_pass = t.done.bind(t); @@ -22,22 +27,23 @@ var t_fail = t.step_func(function(reason) { throw reason; }); t.step(function() { + {% endif %} -{# Test body: #} +{#- Test body: #} var canvas = new OffscreenCanvas({{ size[0] }}, {{ size[1] }}); var ctx = canvas.getContext('2d'{% if attributes %}, {{ attributes }}{% endif %}); - {{ code | trim | indent(2)}} + {{ code_offscreen | trim | indent(2)}} {#- Promise vs. async test footer: +#} -{% if test_type == 'promise' %} - -}, "{{ desc }}"); -{% else %} +{% if not test_type %} t.done(); }); +{% else %} + +}, "{{ desc | double_quote_escape }}"); {% endif %} </script> {% for svgimage in svgimages %} |