offscreen: | OffscreenCanvas test: %(name)s %(timeout)s\

%(name)s

%(desc)s

%(notes)s worker: | %(timeout_js)s\ // DO NOT EDIT! This test has been generated by /html/canvas/tools/gentest.py. // OffscreenCanvas test in a worker:%(name)s // Description:%(desc)s // Note:%(notes)s importScripts("/resources/testharness.js"); importScripts("/html/canvas/resources/canvas-tests.js"); ## Promise vs. async test header: {% if promise_test %}\ promise_test(async t => { {% else %}\ var t = async_test("%(escaped_desc)s"); var t_pass = t.done.bind(t); var t_fail = t.step_func(function(reason) { throw reason; }); t.step(function() { {% endif %}\ ## Test body: var canvas = new OffscreenCanvas(%(width)s, %(height)s); var ctx = canvas.getContext(%(context_args)s); %(code)s t.done();\ ## Promise vs. async test footer: {% if promise_test %}\ }, "%(desc)s"); {% else %}\ }); {% endif %}\ done(); element: | Canvas test: %(name)s %(fonts)s\

%(name)s

%(desc)s

%(notes)s %(fonthack)s\

Actual output:

\- %(fallback)s\ %(expected)s \ %(images)s offscreen_ref_test: |- {% if promise_test %}\ {% endif %}\ %(links)s\ %(fuzzy)s\ %(timeout)s\ Canvas test: %(name)s

%(name)s

%(desc)s

%(fonts)s%(fonthack)s%(notes)s %(fallback)s const canvas = new OffscreenCanvas(%(width)s, %(height)s); const ctx = canvas.getContext(%(context_args)s); %(code)s const outputCanvas = document.getElementById("canvas"); outputCanvas.getContext(%(context_args)s).drawImage(canvas, 0, 0); {% if promise_test %}\ document.documentElement.classList.remove("reftest-wait"); {% endif %}\ %(images)s\ {% if promise_test %}{% endif %} worker_ref_test: | %(links)s\ %(fuzzy)s\ %(timeout)s\ Canvas test: %(name)s

%(name)s

%(desc)s

%(fonts)s%(fonthack)s%(notes)s %(fallback)s %(images)s\ element_ref_test: |- {% if promise_test %}\ {% endif %}\ %(links)s\ %(fuzzy)s\ %(timeout)s\ Canvas test: %(name)s

%(name)s

%(desc)s

%(fonts)s%(fonthack)s%(notes)s %(fallback)s const canvas = document.getElementById("canvas"); const ctx = canvas.getContext(%(context_args)s); %(code)s {% if promise_test %}\ document.documentElement.classList.remove("reftest-wait"); {% endif %}\ %(images)s\ {% if promise_test %}{% endif %} html_ref_test: |- %(links)s\ %(fuzzy)s\ %(timeout)s\ Canvas test: %(name)s

%(name)s

%(desc)s

%(fonts)s%(fonthack)s%(notes)s %(code)s %(images)s