From 26a029d407be480d791972afb5975cf62c9360a6 Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Fri, 19 Apr 2024 02:47:55 +0200 Subject: Adding upstream version 124.0.1. Signed-off-by: Daniel Baumann --- .../canvas/offscreen/reset/2d.reset.basic.html | 36 +++++++++++++++++ .../offscreen/reset/2d.reset.basic.worker.js | 31 +++++++++++++++ .../2d.reset.render.drop_shadow-expected.html | 14 +++++++ .../reset/2d.reset.render.drop_shadow.html | 25 ++++++++++++ .../reset/2d.reset.render.drop_shadow.w.html | 39 +++++++++++++++++++ ...render.global_composite_operation-expected.html | 15 ++++++++ ...2d.reset.render.global_composite_operation.html | 23 +++++++++++ ....reset.render.global_composite_operation.w.html | 37 ++++++++++++++++++ .../reset/2d.reset.render.line-expected.html | 19 +++++++++ .../offscreen/reset/2d.reset.render.line.html | 31 +++++++++++++++ .../offscreen/reset/2d.reset.render.line.w.html | 45 ++++++++++++++++++++++ .../reset/2d.reset.render.misc-expected.html | 15 ++++++++ .../offscreen/reset/2d.reset.render.misc.html | 26 +++++++++++++ .../offscreen/reset/2d.reset.render.misc.w.html | 40 +++++++++++++++++++ .../2d.reset.render.miter_limit-expected.html | 22 +++++++++++ .../reset/2d.reset.render.miter_limit.html | 30 +++++++++++++++ .../reset/2d.reset.render.miter_limit.w.html | 44 +++++++++++++++++++++ .../reset/2d.reset.render.text-expected.html | 14 +++++++ .../offscreen/reset/2d.reset.render.text.html | 31 +++++++++++++++ .../offscreen/reset/2d.reset.render.text.w.html | 45 ++++++++++++++++++++++ .../reset/2d.reset.state.clip-expected.html | 14 +++++++ .../offscreen/reset/2d.reset.state.clip.html | 26 +++++++++++++ .../offscreen/reset/2d.reset.state.clip.w.html | 40 +++++++++++++++++++ .../offscreen/reset/2d.reset.state.direction.html | 33 ++++++++++++++++ .../reset/2d.reset.state.direction.worker.js | 28 ++++++++++++++ .../offscreen/reset/2d.reset.state.fill_style.html | 33 ++++++++++++++++ .../reset/2d.reset.state.fill_style.worker.js | 28 ++++++++++++++ .../offscreen/reset/2d.reset.state.filter.html | 33 ++++++++++++++++ .../reset/2d.reset.state.filter.worker.js | 28 ++++++++++++++ .../offscreen/reset/2d.reset.state.font.html | 33 ++++++++++++++++ .../offscreen/reset/2d.reset.state.font.worker.js | 28 ++++++++++++++ .../reset/2d.reset.state.font_kerning.html | 33 ++++++++++++++++ .../reset/2d.reset.state.font_kerning.worker.js | 28 ++++++++++++++ .../reset/2d.reset.state.font_stretch.html | 33 ++++++++++++++++ .../reset/2d.reset.state.font_stretch.worker.js | 28 ++++++++++++++ .../reset/2d.reset.state.font_variant_caps.html | 33 ++++++++++++++++ .../2d.reset.state.font_variant_caps.worker.js | 28 ++++++++++++++ .../reset/2d.reset.state.global_alpha.html | 33 ++++++++++++++++ .../reset/2d.reset.state.global_alpha.worker.js | 28 ++++++++++++++ .../2d.reset.state.global_composite_operation.html | 33 ++++++++++++++++ ...eset.state.global_composite_operation.worker.js | 28 ++++++++++++++ .../2d.reset.state.image_smoothing_enabled.html | 33 ++++++++++++++++ ...d.reset.state.image_smoothing_enabled.worker.js | 28 ++++++++++++++ .../2d.reset.state.image_smoothing_quality.html | 33 ++++++++++++++++ ...d.reset.state.image_smoothing_quality.worker.js | 28 ++++++++++++++ .../reset/2d.reset.state.letter_spacing.html | 33 ++++++++++++++++ .../reset/2d.reset.state.letter_spacing.worker.js | 28 ++++++++++++++ .../offscreen/reset/2d.reset.state.line_cap.html | 33 ++++++++++++++++ .../reset/2d.reset.state.line_cap.worker.js | 28 ++++++++++++++ .../offscreen/reset/2d.reset.state.line_dash.html | 30 +++++++++++++++ .../reset/2d.reset.state.line_dash.worker.js | 25 ++++++++++++ .../reset/2d.reset.state.line_dash_offset.html | 33 ++++++++++++++++ .../2d.reset.state.line_dash_offset.worker.js | 28 ++++++++++++++ .../offscreen/reset/2d.reset.state.line_join.html | 33 ++++++++++++++++ .../reset/2d.reset.state.line_join.worker.js | 28 ++++++++++++++ .../offscreen/reset/2d.reset.state.line_width.html | 33 ++++++++++++++++ .../reset/2d.reset.state.line_width.worker.js | 28 ++++++++++++++ .../reset/2d.reset.state.miter_limit.html | 33 ++++++++++++++++ .../reset/2d.reset.state.miter_limit.worker.js | 28 ++++++++++++++ .../reset/2d.reset.state.shadow_blur.html | 33 ++++++++++++++++ .../reset/2d.reset.state.shadow_blur.worker.js | 28 ++++++++++++++ .../reset/2d.reset.state.shadow_color.html | 33 ++++++++++++++++ .../reset/2d.reset.state.shadow_color.worker.js | 28 ++++++++++++++ .../reset/2d.reset.state.shadow_offset_x.html | 33 ++++++++++++++++ .../reset/2d.reset.state.shadow_offset_x.worker.js | 28 ++++++++++++++ .../reset/2d.reset.state.shadow_offset_y.html | 33 ++++++++++++++++ .../reset/2d.reset.state.shadow_offset_y.worker.js | 28 ++++++++++++++ .../reset/2d.reset.state.stroke_style.html | 33 ++++++++++++++++ .../reset/2d.reset.state.stroke_style.worker.js | 28 ++++++++++++++ .../offscreen/reset/2d.reset.state.text_align.html | 33 ++++++++++++++++ .../reset/2d.reset.state.text_align.worker.js | 28 ++++++++++++++ .../reset/2d.reset.state.text_baseline.html | 33 ++++++++++++++++ .../reset/2d.reset.state.text_baseline.worker.js | 28 ++++++++++++++ .../reset/2d.reset.state.text_rendering.html | 33 ++++++++++++++++ .../reset/2d.reset.state.text_rendering.worker.js | 28 ++++++++++++++ .../2d.reset.state.transformation_matrix.html | 30 +++++++++++++++ .../2d.reset.state.transformation_matrix.worker.js | 25 ++++++++++++ .../reset/2d.reset.state.word_spacing.html | 33 ++++++++++++++++ .../reset/2d.reset.state.word_spacing.worker.js | 28 ++++++++++++++ 79 files changed, 2358 insertions(+) create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.basic.html create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.basic.worker.js create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.drop_shadow-expected.html create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.drop_shadow.html create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.drop_shadow.w.html create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.global_composite_operation-expected.html create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.global_composite_operation.html create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.global_composite_operation.w.html create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.line-expected.html create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.line.html create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.line.w.html create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.misc-expected.html create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.misc.html create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.misc.w.html create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.miter_limit-expected.html create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.miter_limit.html create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.miter_limit.w.html create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.text-expected.html create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.text.html create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.text.w.html create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.clip-expected.html create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.clip.html create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.clip.w.html create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.direction.html create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.direction.worker.js create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.fill_style.html create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.fill_style.worker.js create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.filter.html create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.filter.worker.js create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.font.html create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.font.worker.js create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.font_kerning.html create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.font_kerning.worker.js create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.font_stretch.html create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.font_stretch.worker.js create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.font_variant_caps.html create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.font_variant_caps.worker.js create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.global_alpha.html create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.global_alpha.worker.js create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.global_composite_operation.html create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.global_composite_operation.worker.js create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.image_smoothing_enabled.html create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.image_smoothing_enabled.worker.js create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.image_smoothing_quality.html create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.image_smoothing_quality.worker.js create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.letter_spacing.html create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.letter_spacing.worker.js create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.line_cap.html create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.line_cap.worker.js create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.line_dash.html create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.line_dash.worker.js create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.line_dash_offset.html create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.line_dash_offset.worker.js create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.line_join.html create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.line_join.worker.js create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.line_width.html create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.line_width.worker.js create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.miter_limit.html create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.miter_limit.worker.js create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.shadow_blur.html create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.shadow_blur.worker.js create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.shadow_color.html create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.shadow_color.worker.js create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.shadow_offset_x.html create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.shadow_offset_x.worker.js create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.shadow_offset_y.html create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.shadow_offset_y.worker.js create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.stroke_style.html create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.stroke_style.worker.js create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.text_align.html create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.text_align.worker.js create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.text_baseline.html create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.text_baseline.worker.js create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.text_rendering.html create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.text_rendering.worker.js create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.transformation_matrix.html create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.transformation_matrix.worker.js create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.word_spacing.html create mode 100644 testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.word_spacing.worker.js (limited to 'testing/web-platform/tests/html/canvas/offscreen/reset') diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.basic.html b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.basic.html new file mode 100644 index 0000000000..7396ca120a --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.basic.html @@ -0,0 +1,36 @@ + + +OffscreenCanvas test: 2d.reset.basic + + + + +

2d.reset.basic

+

reset clears to transparent black

+ + + diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.basic.worker.js b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.basic.worker.js new file mode 100644 index 0000000000..180bffbfac --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.basic.worker.js @@ -0,0 +1,31 @@ +// DO NOT EDIT! This test has been generated by /html/canvas/tools/gentest.py. +// OffscreenCanvas test in a worker:2d.reset.basic +// Description:reset clears to transparent black +// Note: + +importScripts("/resources/testharness.js"); +importScripts("/html/canvas/resources/canvas-tests.js"); + +var t = async_test("reset clears to transparent black"); +var t_pass = t.done.bind(t); +var t_fail = t.step_func(function(reason) { + throw reason; +}); +t.step(function() { + + var canvas = new OffscreenCanvas(100, 50); + var ctx = canvas.getContext('2d'); + + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, ctx.canvas.width, ctx.canvas.height); + ctx.reset(); + _assertPixel(canvas, 0,0, 0,0,0,0); + _assertPixel(canvas, 50,25, 0,0,0,0); + _assertPixel(canvas, 25,50, 0,0,0,0); + _assertPixel(canvas, 100,50, 0,0,0,0); + _assertPixel(canvas, 0,50, 0,0,0,0); + _assertPixel(canvas, 100,0, 0,0,0,0); + t.done(); + t.done(); +}); +done(); diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.drop_shadow-expected.html b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.drop_shadow-expected.html new file mode 100644 index 0000000000..182f7e40cd --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.drop_shadow-expected.html @@ -0,0 +1,14 @@ + + +Canvas test: 2d.reset.render.drop_shadow +

2d.reset.render.drop_shadow

+

check that drop shadows are correctly rendered after reset

+ +

FAIL (fallback content)

+
+ diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.drop_shadow.html b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.drop_shadow.html new file mode 100644 index 0000000000..e6decd1687 --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.drop_shadow.html @@ -0,0 +1,25 @@ + + + +Canvas test: 2d.reset.render.drop_shadow +

2d.reset.render.drop_shadow

+

check that drop shadows are correctly rendered after reset

+ +

FAIL (fallback content)

+
+ diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.drop_shadow.w.html b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.drop_shadow.w.html new file mode 100644 index 0000000000..0ceba2f91d --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.drop_shadow.w.html @@ -0,0 +1,39 @@ + + + + +Canvas test: 2d.reset.render.drop_shadow +

2d.reset.render.drop_shadow

+

check that drop shadows are correctly rendered after reset

+ +

FAIL (fallback content)

+
+ + + diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.global_composite_operation-expected.html b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.global_composite_operation-expected.html new file mode 100644 index 0000000000..1f9d247634 --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.global_composite_operation-expected.html @@ -0,0 +1,15 @@ + + +Canvas test: 2d.reset.render.global_composite_operation +

2d.reset.render.global_composite_operation

+

check that canvas correctly renders rectangles with the default global composite operation after reset

+ +

FAIL (fallback content)

+
+ diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.global_composite_operation.html b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.global_composite_operation.html new file mode 100644 index 0000000000..4ddcc8d8f0 --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.global_composite_operation.html @@ -0,0 +1,23 @@ + + + +Canvas test: 2d.reset.render.global_composite_operation +

2d.reset.render.global_composite_operation

+

check that canvas correctly renders rectangles with the default global composite operation after reset

+ +

FAIL (fallback content)

+
+ diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.global_composite_operation.w.html b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.global_composite_operation.w.html new file mode 100644 index 0000000000..6df07a47e2 --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.global_composite_operation.w.html @@ -0,0 +1,37 @@ + + + + +Canvas test: 2d.reset.render.global_composite_operation +

2d.reset.render.global_composite_operation

+

check that canvas correctly renders rectangles with the default global composite operation after reset

+ +

FAIL (fallback content)

+
+ + + diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.line-expected.html b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.line-expected.html new file mode 100644 index 0000000000..dcd648d8c3 --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.line-expected.html @@ -0,0 +1,19 @@ + + +Canvas test: 2d.reset.render.line +

2d.reset.render.line

+

check that lines are correctly rendered after reset

+ +

FAIL (fallback content)

+
+ diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.line.html b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.line.html new file mode 100644 index 0000000000..0e478cbf9d --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.line.html @@ -0,0 +1,31 @@ + + + +Canvas test: 2d.reset.render.line +

2d.reset.render.line

+

check that lines are correctly rendered after reset

+ +

FAIL (fallback content)

+
+ diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.line.w.html b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.line.w.html new file mode 100644 index 0000000000..e85f155b32 --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.line.w.html @@ -0,0 +1,45 @@ + + + + +Canvas test: 2d.reset.render.line +

2d.reset.render.line

+

check that lines are correctly rendered after reset

+ +

FAIL (fallback content)

+
+ + + diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.misc-expected.html b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.misc-expected.html new file mode 100644 index 0000000000..c359e6b42e --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.misc-expected.html @@ -0,0 +1,15 @@ + + +Canvas test: 2d.reset.render.misc +

2d.reset.render.misc

+

check that canvas correctly renders rectangles after reset (states not covered by other tests)

+ +

FAIL (fallback content)

+
+ diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.misc.html b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.misc.html new file mode 100644 index 0000000000..b471327d98 --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.misc.html @@ -0,0 +1,26 @@ + + + +Canvas test: 2d.reset.render.misc +

2d.reset.render.misc

+

check that canvas correctly renders rectangles after reset (states not covered by other tests)

+ +

FAIL (fallback content)

+
+ diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.misc.w.html b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.misc.w.html new file mode 100644 index 0000000000..eef646df66 --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.misc.w.html @@ -0,0 +1,40 @@ + + + + +Canvas test: 2d.reset.render.misc +

2d.reset.render.misc

+

check that canvas correctly renders rectangles after reset (states not covered by other tests)

+ +

FAIL (fallback content)

+
+ + + diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.miter_limit-expected.html b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.miter_limit-expected.html new file mode 100644 index 0000000000..c91f485c53 --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.miter_limit-expected.html @@ -0,0 +1,22 @@ + + +Canvas test: 2d.reset.render.miter_limit +

2d.reset.render.miter_limit

+

check that the lines are correctly rendered with the default miter limit after reset

+ +

FAIL (fallback content)

+
+ diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.miter_limit.html b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.miter_limit.html new file mode 100644 index 0000000000..c00284bbc2 --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.miter_limit.html @@ -0,0 +1,30 @@ + + + +Canvas test: 2d.reset.render.miter_limit +

2d.reset.render.miter_limit

+

check that the lines are correctly rendered with the default miter limit after reset

+ +

FAIL (fallback content)

+
+ diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.miter_limit.w.html b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.miter_limit.w.html new file mode 100644 index 0000000000..1f98606b55 --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.miter_limit.w.html @@ -0,0 +1,44 @@ + + + + +Canvas test: 2d.reset.render.miter_limit +

2d.reset.render.miter_limit

+

check that the lines are correctly rendered with the default miter limit after reset

+ +

FAIL (fallback content)

+
+ + + diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.text-expected.html b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.text-expected.html new file mode 100644 index 0000000000..7221483b02 --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.text-expected.html @@ -0,0 +1,14 @@ + + +Canvas test: 2d.reset.render.text +

2d.reset.render.text

+

check that text is correctly rendered after reset

+ +

FAIL (fallback content)

+
+ diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.text.html b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.text.html new file mode 100644 index 0000000000..31e35db71c --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.text.html @@ -0,0 +1,31 @@ + + + +Canvas test: 2d.reset.render.text +

2d.reset.render.text

+

check that text is correctly rendered after reset

+ +

FAIL (fallback content)

+
+ diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.text.w.html b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.text.w.html new file mode 100644 index 0000000000..6ddfd9fd9d --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.render.text.w.html @@ -0,0 +1,45 @@ + + + + +Canvas test: 2d.reset.render.text +

2d.reset.render.text

+

check that text is correctly rendered after reset

+ +

FAIL (fallback content)

+
+ + + diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.clip-expected.html b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.clip-expected.html new file mode 100644 index 0000000000..974b37fab4 --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.clip-expected.html @@ -0,0 +1,14 @@ + + +Canvas test: 2d.reset.state.clip +

2d.reset.state.clip

+

check that the clip is reset

+ +

FAIL (fallback content)

+
+ diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.clip.html b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.clip.html new file mode 100644 index 0000000000..2f53da7a49 --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.clip.html @@ -0,0 +1,26 @@ + + + +Canvas test: 2d.reset.state.clip +

2d.reset.state.clip

+

check that the clip is reset

+ +

FAIL (fallback content)

+
+ diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.clip.w.html b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.clip.w.html new file mode 100644 index 0000000000..ec4bdf5b23 --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.clip.w.html @@ -0,0 +1,40 @@ + + + + +Canvas test: 2d.reset.state.clip +

2d.reset.state.clip

+

check that the clip is reset

+ +

FAIL (fallback content)

+
+ + + diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.direction.html b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.direction.html new file mode 100644 index 0000000000..f2dc299e97 --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.direction.html @@ -0,0 +1,33 @@ + + +OffscreenCanvas test: 2d.reset.state.direction + + + + +

2d.reset.state.direction

+

check that the state is reset

+ + + diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.direction.worker.js b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.direction.worker.js new file mode 100644 index 0000000000..3d6b835050 --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.direction.worker.js @@ -0,0 +1,28 @@ +// DO NOT EDIT! This test has been generated by /html/canvas/tools/gentest.py. +// OffscreenCanvas test in a worker:2d.reset.state.direction +// Description:check that the state is reset +// Note: + +importScripts("/resources/testharness.js"); +importScripts("/html/canvas/resources/canvas-tests.js"); + +var t = async_test("check that the state is reset"); +var t_pass = t.done.bind(t); +var t_fail = t.step_func(function(reason) { + throw reason; +}); +t.step(function() { + + var canvas = new OffscreenCanvas(100, 50); + var ctx = canvas.getContext('2d'); + + const default_value = ctx.direction; + + ctx.direction = 'rtl'; + _assert(ctx.direction == 'rtl', "ctx.direction == 'rtl'"); + + ctx.reset(); + _assert(ctx.direction == default_value, "ctx.direction == default_value"); + t.done(); +}); +done(); diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.fill_style.html b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.fill_style.html new file mode 100644 index 0000000000..1fdd2b773a --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.fill_style.html @@ -0,0 +1,33 @@ + + +OffscreenCanvas test: 2d.reset.state.fill_style + + + + +

2d.reset.state.fill_style

+

check that the state is reset

+ + + diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.fill_style.worker.js b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.fill_style.worker.js new file mode 100644 index 0000000000..c574824b0a --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.fill_style.worker.js @@ -0,0 +1,28 @@ +// DO NOT EDIT! This test has been generated by /html/canvas/tools/gentest.py. +// OffscreenCanvas test in a worker:2d.reset.state.fill_style +// Description:check that the state is reset +// Note: + +importScripts("/resources/testharness.js"); +importScripts("/html/canvas/resources/canvas-tests.js"); + +var t = async_test("check that the state is reset"); +var t_pass = t.done.bind(t); +var t_fail = t.step_func(function(reason) { + throw reason; +}); +t.step(function() { + + var canvas = new OffscreenCanvas(100, 50); + var ctx = canvas.getContext('2d'); + + const default_value = ctx.fillStyle; + + ctx.fillStyle = '#ffffff'; + _assert(ctx.fillStyle == '#ffffff', "ctx.fillStyle == '#ffffff'"); + + ctx.reset(); + _assert(ctx.fillStyle == default_value, "ctx.fillStyle == default_value"); + t.done(); +}); +done(); diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.filter.html b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.filter.html new file mode 100644 index 0000000000..af898c7dd1 --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.filter.html @@ -0,0 +1,33 @@ + + +OffscreenCanvas test: 2d.reset.state.filter + + + + +

2d.reset.state.filter

+

check that the state is reset

+ + + diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.filter.worker.js b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.filter.worker.js new file mode 100644 index 0000000000..f781a9fa34 --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.filter.worker.js @@ -0,0 +1,28 @@ +// DO NOT EDIT! This test has been generated by /html/canvas/tools/gentest.py. +// OffscreenCanvas test in a worker:2d.reset.state.filter +// Description:check that the state is reset +// Note: + +importScripts("/resources/testharness.js"); +importScripts("/html/canvas/resources/canvas-tests.js"); + +var t = async_test("check that the state is reset"); +var t_pass = t.done.bind(t); +var t_fail = t.step_func(function(reason) { + throw reason; +}); +t.step(function() { + + var canvas = new OffscreenCanvas(100, 50); + var ctx = canvas.getContext('2d'); + + const default_value = ctx.filter; + + ctx.filter = 'blur(10px)'; + _assert(ctx.filter == 'blur(10px)', "ctx.filter == 'blur(10px)'"); + + ctx.reset(); + _assert(ctx.filter == default_value, "ctx.filter == default_value"); + t.done(); +}); +done(); diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.font.html b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.font.html new file mode 100644 index 0000000000..69bbf3261e --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.font.html @@ -0,0 +1,33 @@ + + +OffscreenCanvas test: 2d.reset.state.font + + + + +

2d.reset.state.font

+

check that the state is reset

+ + + diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.font.worker.js b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.font.worker.js new file mode 100644 index 0000000000..ea6f4cc184 --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.font.worker.js @@ -0,0 +1,28 @@ +// DO NOT EDIT! This test has been generated by /html/canvas/tools/gentest.py. +// OffscreenCanvas test in a worker:2d.reset.state.font +// Description:check that the state is reset +// Note: + +importScripts("/resources/testharness.js"); +importScripts("/html/canvas/resources/canvas-tests.js"); + +var t = async_test("check that the state is reset"); +var t_pass = t.done.bind(t); +var t_fail = t.step_func(function(reason) { + throw reason; +}); +t.step(function() { + + var canvas = new OffscreenCanvas(100, 50); + var ctx = canvas.getContext('2d'); + + const default_value = ctx.font; + + ctx.font = '16px sans-serif'; + _assert(ctx.font == '16px sans-serif', "ctx.font == '16px sans-serif'"); + + ctx.reset(); + _assert(ctx.font == default_value, "ctx.font == default_value"); + t.done(); +}); +done(); diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.font_kerning.html b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.font_kerning.html new file mode 100644 index 0000000000..27954486c0 --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.font_kerning.html @@ -0,0 +1,33 @@ + + +OffscreenCanvas test: 2d.reset.state.font_kerning + + + + +

2d.reset.state.font_kerning

+

check that the state is reset

+ + + diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.font_kerning.worker.js b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.font_kerning.worker.js new file mode 100644 index 0000000000..1c21249b9c --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.font_kerning.worker.js @@ -0,0 +1,28 @@ +// DO NOT EDIT! This test has been generated by /html/canvas/tools/gentest.py. +// OffscreenCanvas test in a worker:2d.reset.state.font_kerning +// Description:check that the state is reset +// Note: + +importScripts("/resources/testharness.js"); +importScripts("/html/canvas/resources/canvas-tests.js"); + +var t = async_test("check that the state is reset"); +var t_pass = t.done.bind(t); +var t_fail = t.step_func(function(reason) { + throw reason; +}); +t.step(function() { + + var canvas = new OffscreenCanvas(100, 50); + var ctx = canvas.getContext('2d'); + + const default_value = ctx.fontKerning; + + ctx.fontKerning = 'normal'; + _assert(ctx.fontKerning == 'normal', "ctx.fontKerning == 'normal'"); + + ctx.reset(); + _assert(ctx.fontKerning == default_value, "ctx.fontKerning == default_value"); + t.done(); +}); +done(); diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.font_stretch.html b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.font_stretch.html new file mode 100644 index 0000000000..b1e2217320 --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.font_stretch.html @@ -0,0 +1,33 @@ + + +OffscreenCanvas test: 2d.reset.state.font_stretch + + + + +

2d.reset.state.font_stretch

+

check that the state is reset

+ + + diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.font_stretch.worker.js b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.font_stretch.worker.js new file mode 100644 index 0000000000..71bb6aff48 --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.font_stretch.worker.js @@ -0,0 +1,28 @@ +// DO NOT EDIT! This test has been generated by /html/canvas/tools/gentest.py. +// OffscreenCanvas test in a worker:2d.reset.state.font_stretch +// Description:check that the state is reset +// Note: + +importScripts("/resources/testharness.js"); +importScripts("/html/canvas/resources/canvas-tests.js"); + +var t = async_test("check that the state is reset"); +var t_pass = t.done.bind(t); +var t_fail = t.step_func(function(reason) { + throw reason; +}); +t.step(function() { + + var canvas = new OffscreenCanvas(100, 50); + var ctx = canvas.getContext('2d'); + + const default_value = ctx.fontStretch; + + ctx.fontStretch = 'ultra-condensed'; + _assert(ctx.fontStretch == 'ultra-condensed', "ctx.fontStretch == 'ultra-condensed'"); + + ctx.reset(); + _assert(ctx.fontStretch == default_value, "ctx.fontStretch == default_value"); + t.done(); +}); +done(); diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.font_variant_caps.html b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.font_variant_caps.html new file mode 100644 index 0000000000..7d0518c021 --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.font_variant_caps.html @@ -0,0 +1,33 @@ + + +OffscreenCanvas test: 2d.reset.state.font_variant_caps + + + + +

2d.reset.state.font_variant_caps

+

check that the state is reset

+ + + diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.font_variant_caps.worker.js b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.font_variant_caps.worker.js new file mode 100644 index 0000000000..e89a8bda42 --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.font_variant_caps.worker.js @@ -0,0 +1,28 @@ +// DO NOT EDIT! This test has been generated by /html/canvas/tools/gentest.py. +// OffscreenCanvas test in a worker:2d.reset.state.font_variant_caps +// Description:check that the state is reset +// Note: + +importScripts("/resources/testharness.js"); +importScripts("/html/canvas/resources/canvas-tests.js"); + +var t = async_test("check that the state is reset"); +var t_pass = t.done.bind(t); +var t_fail = t.step_func(function(reason) { + throw reason; +}); +t.step(function() { + + var canvas = new OffscreenCanvas(100, 50); + var ctx = canvas.getContext('2d'); + + const default_value = ctx.fontVariantCaps; + + ctx.fontVariantCaps = 'unicase'; + _assert(ctx.fontVariantCaps == 'unicase', "ctx.fontVariantCaps == 'unicase'"); + + ctx.reset(); + _assert(ctx.fontVariantCaps == default_value, "ctx.fontVariantCaps == default_value"); + t.done(); +}); +done(); diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.global_alpha.html b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.global_alpha.html new file mode 100644 index 0000000000..fe87aedf84 --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.global_alpha.html @@ -0,0 +1,33 @@ + + +OffscreenCanvas test: 2d.reset.state.global_alpha + + + + +

2d.reset.state.global_alpha

+

check that the state is reset

+ + + diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.global_alpha.worker.js b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.global_alpha.worker.js new file mode 100644 index 0000000000..518a8cbb46 --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.global_alpha.worker.js @@ -0,0 +1,28 @@ +// DO NOT EDIT! This test has been generated by /html/canvas/tools/gentest.py. +// OffscreenCanvas test in a worker:2d.reset.state.global_alpha +// Description:check that the state is reset +// Note: + +importScripts("/resources/testharness.js"); +importScripts("/html/canvas/resources/canvas-tests.js"); + +var t = async_test("check that the state is reset"); +var t_pass = t.done.bind(t); +var t_fail = t.step_func(function(reason) { + throw reason; +}); +t.step(function() { + + var canvas = new OffscreenCanvas(100, 50); + var ctx = canvas.getContext('2d'); + + const default_value = ctx.globalAlpha; + + ctx.globalAlpha = 0.5; + _assert(ctx.globalAlpha == 0.5, "ctx.globalAlpha == 0.5"); + + ctx.reset(); + _assert(ctx.globalAlpha == default_value, "ctx.globalAlpha == default_value"); + t.done(); +}); +done(); diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.global_composite_operation.html b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.global_composite_operation.html new file mode 100644 index 0000000000..647349c94a --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.global_composite_operation.html @@ -0,0 +1,33 @@ + + +OffscreenCanvas test: 2d.reset.state.global_composite_operation + + + + +

2d.reset.state.global_composite_operation

+

check that the state is reset

+ + + diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.global_composite_operation.worker.js b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.global_composite_operation.worker.js new file mode 100644 index 0000000000..c94f15b232 --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.global_composite_operation.worker.js @@ -0,0 +1,28 @@ +// DO NOT EDIT! This test has been generated by /html/canvas/tools/gentest.py. +// OffscreenCanvas test in a worker:2d.reset.state.global_composite_operation +// Description:check that the state is reset +// Note: + +importScripts("/resources/testharness.js"); +importScripts("/html/canvas/resources/canvas-tests.js"); + +var t = async_test("check that the state is reset"); +var t_pass = t.done.bind(t); +var t_fail = t.step_func(function(reason) { + throw reason; +}); +t.step(function() { + + var canvas = new OffscreenCanvas(100, 50); + var ctx = canvas.getContext('2d'); + + const default_value = ctx.globalCompositeOperation; + + ctx.globalCompositeOperation = 'destination-over'; + _assert(ctx.globalCompositeOperation == 'destination-over', "ctx.globalCompositeOperation == 'destination-over'"); + + ctx.reset(); + _assert(ctx.globalCompositeOperation == default_value, "ctx.globalCompositeOperation == default_value"); + t.done(); +}); +done(); diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.image_smoothing_enabled.html b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.image_smoothing_enabled.html new file mode 100644 index 0000000000..c0b7f29aca --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.image_smoothing_enabled.html @@ -0,0 +1,33 @@ + + +OffscreenCanvas test: 2d.reset.state.image_smoothing_enabled + + + + +

2d.reset.state.image_smoothing_enabled

+

check that the state is reset

+ + + diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.image_smoothing_enabled.worker.js b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.image_smoothing_enabled.worker.js new file mode 100644 index 0000000000..7010fb899c --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.image_smoothing_enabled.worker.js @@ -0,0 +1,28 @@ +// DO NOT EDIT! This test has been generated by /html/canvas/tools/gentest.py. +// OffscreenCanvas test in a worker:2d.reset.state.image_smoothing_enabled +// Description:check that the state is reset +// Note: + +importScripts("/resources/testharness.js"); +importScripts("/html/canvas/resources/canvas-tests.js"); + +var t = async_test("check that the state is reset"); +var t_pass = t.done.bind(t); +var t_fail = t.step_func(function(reason) { + throw reason; +}); +t.step(function() { + + var canvas = new OffscreenCanvas(100, 50); + var ctx = canvas.getContext('2d'); + + const default_value = ctx.imageSmoothingEnabled; + + ctx.imageSmoothingEnabled = false; + _assert(ctx.imageSmoothingEnabled == false, "ctx.imageSmoothingEnabled == false"); + + ctx.reset(); + _assert(ctx.imageSmoothingEnabled == default_value, "ctx.imageSmoothingEnabled == default_value"); + t.done(); +}); +done(); diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.image_smoothing_quality.html b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.image_smoothing_quality.html new file mode 100644 index 0000000000..12a6367ff9 --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.image_smoothing_quality.html @@ -0,0 +1,33 @@ + + +OffscreenCanvas test: 2d.reset.state.image_smoothing_quality + + + + +

2d.reset.state.image_smoothing_quality

+

check that the state is reset

+ + + diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.image_smoothing_quality.worker.js b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.image_smoothing_quality.worker.js new file mode 100644 index 0000000000..7429666691 --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.image_smoothing_quality.worker.js @@ -0,0 +1,28 @@ +// DO NOT EDIT! This test has been generated by /html/canvas/tools/gentest.py. +// OffscreenCanvas test in a worker:2d.reset.state.image_smoothing_quality +// Description:check that the state is reset +// Note: + +importScripts("/resources/testharness.js"); +importScripts("/html/canvas/resources/canvas-tests.js"); + +var t = async_test("check that the state is reset"); +var t_pass = t.done.bind(t); +var t_fail = t.step_func(function(reason) { + throw reason; +}); +t.step(function() { + + var canvas = new OffscreenCanvas(100, 50); + var ctx = canvas.getContext('2d'); + + const default_value = ctx.imageSmoothingQuality; + + ctx.imageSmoothingQuality = 'high'; + _assert(ctx.imageSmoothingQuality == 'high', "ctx.imageSmoothingQuality == 'high'"); + + ctx.reset(); + _assert(ctx.imageSmoothingQuality == default_value, "ctx.imageSmoothingQuality == default_value"); + t.done(); +}); +done(); diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.letter_spacing.html b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.letter_spacing.html new file mode 100644 index 0000000000..addb0c62ad --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.letter_spacing.html @@ -0,0 +1,33 @@ + + +OffscreenCanvas test: 2d.reset.state.letter_spacing + + + + +

2d.reset.state.letter_spacing

+

check that the state is reset

+ + + diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.letter_spacing.worker.js b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.letter_spacing.worker.js new file mode 100644 index 0000000000..e0dfae0a8e --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.letter_spacing.worker.js @@ -0,0 +1,28 @@ +// DO NOT EDIT! This test has been generated by /html/canvas/tools/gentest.py. +// OffscreenCanvas test in a worker:2d.reset.state.letter_spacing +// Description:check that the state is reset +// Note: + +importScripts("/resources/testharness.js"); +importScripts("/html/canvas/resources/canvas-tests.js"); + +var t = async_test("check that the state is reset"); +var t_pass = t.done.bind(t); +var t_fail = t.step_func(function(reason) { + throw reason; +}); +t.step(function() { + + var canvas = new OffscreenCanvas(100, 50); + var ctx = canvas.getContext('2d'); + + const default_value = ctx.letterSpacing; + + ctx.letterSpacing = '12px'; + _assert(ctx.letterSpacing == '12px', "ctx.letterSpacing == '12px'"); + + ctx.reset(); + _assert(ctx.letterSpacing == default_value, "ctx.letterSpacing == default_value"); + t.done(); +}); +done(); diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.line_cap.html b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.line_cap.html new file mode 100644 index 0000000000..9b528b3448 --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.line_cap.html @@ -0,0 +1,33 @@ + + +OffscreenCanvas test: 2d.reset.state.line_cap + + + + +

2d.reset.state.line_cap

+

check that the state is reset

+ + + diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.line_cap.worker.js b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.line_cap.worker.js new file mode 100644 index 0000000000..c3a94f2cbb --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.line_cap.worker.js @@ -0,0 +1,28 @@ +// DO NOT EDIT! This test has been generated by /html/canvas/tools/gentest.py. +// OffscreenCanvas test in a worker:2d.reset.state.line_cap +// Description:check that the state is reset +// Note: + +importScripts("/resources/testharness.js"); +importScripts("/html/canvas/resources/canvas-tests.js"); + +var t = async_test("check that the state is reset"); +var t_pass = t.done.bind(t); +var t_fail = t.step_func(function(reason) { + throw reason; +}); +t.step(function() { + + var canvas = new OffscreenCanvas(100, 50); + var ctx = canvas.getContext('2d'); + + const default_value = ctx.lineCap; + + ctx.lineCap = 'square'; + _assert(ctx.lineCap == 'square', "ctx.lineCap == 'square'"); + + ctx.reset(); + _assert(ctx.lineCap == default_value, "ctx.lineCap == default_value"); + t.done(); +}); +done(); diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.line_dash.html b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.line_dash.html new file mode 100644 index 0000000000..fd4edf58cf --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.line_dash.html @@ -0,0 +1,30 @@ + + +OffscreenCanvas test: 2d.reset.state.line_dash + + + + +

2d.reset.state.line_dash

+

check that the line dash is reset

+ + + diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.line_dash.worker.js b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.line_dash.worker.js new file mode 100644 index 0000000000..841475d876 --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.line_dash.worker.js @@ -0,0 +1,25 @@ +// DO NOT EDIT! This test has been generated by /html/canvas/tools/gentest.py. +// OffscreenCanvas test in a worker:2d.reset.state.line_dash +// Description:check that the line dash is reset +// Note: + +importScripts("/resources/testharness.js"); +importScripts("/html/canvas/resources/canvas-tests.js"); + +var t = async_test("check that the line dash is reset"); +var t_pass = t.done.bind(t); +var t_fail = t.step_func(function(reason) { + throw reason; +}); +t.step(function() { + + var canvas = new OffscreenCanvas(100, 50); + var ctx = canvas.getContext('2d'); + + ctx.setLineDash([1, 2]); + + ctx.reset(); + _assert(ctx.getLineDash().length == 0, "ctx.getLineDash().length == 0"); + t.done(); +}); +done(); diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.line_dash_offset.html b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.line_dash_offset.html new file mode 100644 index 0000000000..475db49f82 --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.line_dash_offset.html @@ -0,0 +1,33 @@ + + +OffscreenCanvas test: 2d.reset.state.line_dash_offset + + + + +

2d.reset.state.line_dash_offset

+

check that the state is reset

+ + + diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.line_dash_offset.worker.js b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.line_dash_offset.worker.js new file mode 100644 index 0000000000..5e0d8dd47c --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.line_dash_offset.worker.js @@ -0,0 +1,28 @@ +// DO NOT EDIT! This test has been generated by /html/canvas/tools/gentest.py. +// OffscreenCanvas test in a worker:2d.reset.state.line_dash_offset +// Description:check that the state is reset +// Note: + +importScripts("/resources/testharness.js"); +importScripts("/html/canvas/resources/canvas-tests.js"); + +var t = async_test("check that the state is reset"); +var t_pass = t.done.bind(t); +var t_fail = t.step_func(function(reason) { + throw reason; +}); +t.step(function() { + + var canvas = new OffscreenCanvas(100, 50); + var ctx = canvas.getContext('2d'); + + const default_value = ctx.lineDashOffset; + + ctx.lineDashOffset = 1.0; + _assert(ctx.lineDashOffset == 1.0, "ctx.lineDashOffset == 1.0"); + + ctx.reset(); + _assert(ctx.lineDashOffset == default_value, "ctx.lineDashOffset == default_value"); + t.done(); +}); +done(); diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.line_join.html b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.line_join.html new file mode 100644 index 0000000000..793c1d9bc4 --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.line_join.html @@ -0,0 +1,33 @@ + + +OffscreenCanvas test: 2d.reset.state.line_join + + + + +

2d.reset.state.line_join

+

check that the state is reset

+ + + diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.line_join.worker.js b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.line_join.worker.js new file mode 100644 index 0000000000..9d5e76757b --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.line_join.worker.js @@ -0,0 +1,28 @@ +// DO NOT EDIT! This test has been generated by /html/canvas/tools/gentest.py. +// OffscreenCanvas test in a worker:2d.reset.state.line_join +// Description:check that the state is reset +// Note: + +importScripts("/resources/testharness.js"); +importScripts("/html/canvas/resources/canvas-tests.js"); + +var t = async_test("check that the state is reset"); +var t_pass = t.done.bind(t); +var t_fail = t.step_func(function(reason) { + throw reason; +}); +t.step(function() { + + var canvas = new OffscreenCanvas(100, 50); + var ctx = canvas.getContext('2d'); + + const default_value = ctx.lineJoin; + + ctx.lineJoin = 'bevel'; + _assert(ctx.lineJoin == 'bevel', "ctx.lineJoin == 'bevel'"); + + ctx.reset(); + _assert(ctx.lineJoin == default_value, "ctx.lineJoin == default_value"); + t.done(); +}); +done(); diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.line_width.html b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.line_width.html new file mode 100644 index 0000000000..8cdf45f700 --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.line_width.html @@ -0,0 +1,33 @@ + + +OffscreenCanvas test: 2d.reset.state.line_width + + + + +

2d.reset.state.line_width

+

check that the state is reset

+ + + diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.line_width.worker.js b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.line_width.worker.js new file mode 100644 index 0000000000..1e28f93d66 --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.line_width.worker.js @@ -0,0 +1,28 @@ +// DO NOT EDIT! This test has been generated by /html/canvas/tools/gentest.py. +// OffscreenCanvas test in a worker:2d.reset.state.line_width +// Description:check that the state is reset +// Note: + +importScripts("/resources/testharness.js"); +importScripts("/html/canvas/resources/canvas-tests.js"); + +var t = async_test("check that the state is reset"); +var t_pass = t.done.bind(t); +var t_fail = t.step_func(function(reason) { + throw reason; +}); +t.step(function() { + + var canvas = new OffscreenCanvas(100, 50); + var ctx = canvas.getContext('2d'); + + const default_value = ctx.lineWidth; + + ctx.lineWidth = 1; + _assert(ctx.lineWidth == 1, "ctx.lineWidth == 1"); + + ctx.reset(); + _assert(ctx.lineWidth == default_value, "ctx.lineWidth == default_value"); + t.done(); +}); +done(); diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.miter_limit.html b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.miter_limit.html new file mode 100644 index 0000000000..7f47f9a6be --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.miter_limit.html @@ -0,0 +1,33 @@ + + +OffscreenCanvas test: 2d.reset.state.miter_limit + + + + +

2d.reset.state.miter_limit

+

check that the state is reset

+ + + diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.miter_limit.worker.js b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.miter_limit.worker.js new file mode 100644 index 0000000000..3945a662d4 --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.miter_limit.worker.js @@ -0,0 +1,28 @@ +// DO NOT EDIT! This test has been generated by /html/canvas/tools/gentest.py. +// OffscreenCanvas test in a worker:2d.reset.state.miter_limit +// Description:check that the state is reset +// Note: + +importScripts("/resources/testharness.js"); +importScripts("/html/canvas/resources/canvas-tests.js"); + +var t = async_test("check that the state is reset"); +var t_pass = t.done.bind(t); +var t_fail = t.step_func(function(reason) { + throw reason; +}); +t.step(function() { + + var canvas = new OffscreenCanvas(100, 50); + var ctx = canvas.getContext('2d'); + + const default_value = ctx.miterLimit; + + ctx.miterLimit = 1.0; + _assert(ctx.miterLimit == 1.0, "ctx.miterLimit == 1.0"); + + ctx.reset(); + _assert(ctx.miterLimit == default_value, "ctx.miterLimit == default_value"); + t.done(); +}); +done(); diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.shadow_blur.html b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.shadow_blur.html new file mode 100644 index 0000000000..e7075ce102 --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.shadow_blur.html @@ -0,0 +1,33 @@ + + +OffscreenCanvas test: 2d.reset.state.shadow_blur + + + + +

2d.reset.state.shadow_blur

+

check that the state is reset

+ + + diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.shadow_blur.worker.js b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.shadow_blur.worker.js new file mode 100644 index 0000000000..d82933169d --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.shadow_blur.worker.js @@ -0,0 +1,28 @@ +// DO NOT EDIT! This test has been generated by /html/canvas/tools/gentest.py. +// OffscreenCanvas test in a worker:2d.reset.state.shadow_blur +// Description:check that the state is reset +// Note: + +importScripts("/resources/testharness.js"); +importScripts("/html/canvas/resources/canvas-tests.js"); + +var t = async_test("check that the state is reset"); +var t_pass = t.done.bind(t); +var t_fail = t.step_func(function(reason) { + throw reason; +}); +t.step(function() { + + var canvas = new OffscreenCanvas(100, 50); + var ctx = canvas.getContext('2d'); + + const default_value = ctx.shadowBlur; + + ctx.shadowBlur = 10.0; + _assert(ctx.shadowBlur == 10.0, "ctx.shadowBlur == 10.0"); + + ctx.reset(); + _assert(ctx.shadowBlur == default_value, "ctx.shadowBlur == default_value"); + t.done(); +}); +done(); diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.shadow_color.html b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.shadow_color.html new file mode 100644 index 0000000000..ad928acf46 --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.shadow_color.html @@ -0,0 +1,33 @@ + + +OffscreenCanvas test: 2d.reset.state.shadow_color + + + + +

2d.reset.state.shadow_color

+

check that the state is reset

+ + + diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.shadow_color.worker.js b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.shadow_color.worker.js new file mode 100644 index 0000000000..6ad1e83be2 --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.shadow_color.worker.js @@ -0,0 +1,28 @@ +// DO NOT EDIT! This test has been generated by /html/canvas/tools/gentest.py. +// OffscreenCanvas test in a worker:2d.reset.state.shadow_color +// Description:check that the state is reset +// Note: + +importScripts("/resources/testharness.js"); +importScripts("/html/canvas/resources/canvas-tests.js"); + +var t = async_test("check that the state is reset"); +var t_pass = t.done.bind(t); +var t_fail = t.step_func(function(reason) { + throw reason; +}); +t.step(function() { + + var canvas = new OffscreenCanvas(100, 50); + var ctx = canvas.getContext('2d'); + + const default_value = ctx.shadowColor; + + ctx.shadowColor = '#ff0000'; + _assert(ctx.shadowColor == '#ff0000', "ctx.shadowColor == '#ff0000'"); + + ctx.reset(); + _assert(ctx.shadowColor == default_value, "ctx.shadowColor == default_value"); + t.done(); +}); +done(); diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.shadow_offset_x.html b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.shadow_offset_x.html new file mode 100644 index 0000000000..e3742e4dbc --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.shadow_offset_x.html @@ -0,0 +1,33 @@ + + +OffscreenCanvas test: 2d.reset.state.shadow_offset_x + + + + +

2d.reset.state.shadow_offset_x

+

check that the state is reset

+ + + diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.shadow_offset_x.worker.js b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.shadow_offset_x.worker.js new file mode 100644 index 0000000000..4247820a4d --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.shadow_offset_x.worker.js @@ -0,0 +1,28 @@ +// DO NOT EDIT! This test has been generated by /html/canvas/tools/gentest.py. +// OffscreenCanvas test in a worker:2d.reset.state.shadow_offset_x +// Description:check that the state is reset +// Note: + +importScripts("/resources/testharness.js"); +importScripts("/html/canvas/resources/canvas-tests.js"); + +var t = async_test("check that the state is reset"); +var t_pass = t.done.bind(t); +var t_fail = t.step_func(function(reason) { + throw reason; +}); +t.step(function() { + + var canvas = new OffscreenCanvas(100, 50); + var ctx = canvas.getContext('2d'); + + const default_value = ctx.shadowOffsetX; + + ctx.shadowOffsetX = 10.0; + _assert(ctx.shadowOffsetX == 10.0, "ctx.shadowOffsetX == 10.0"); + + ctx.reset(); + _assert(ctx.shadowOffsetX == default_value, "ctx.shadowOffsetX == default_value"); + t.done(); +}); +done(); diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.shadow_offset_y.html b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.shadow_offset_y.html new file mode 100644 index 0000000000..64901ef492 --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.shadow_offset_y.html @@ -0,0 +1,33 @@ + + +OffscreenCanvas test: 2d.reset.state.shadow_offset_y + + + + +

2d.reset.state.shadow_offset_y

+

check that the state is reset

+ + + diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.shadow_offset_y.worker.js b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.shadow_offset_y.worker.js new file mode 100644 index 0000000000..0c1926ebca --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.shadow_offset_y.worker.js @@ -0,0 +1,28 @@ +// DO NOT EDIT! This test has been generated by /html/canvas/tools/gentest.py. +// OffscreenCanvas test in a worker:2d.reset.state.shadow_offset_y +// Description:check that the state is reset +// Note: + +importScripts("/resources/testharness.js"); +importScripts("/html/canvas/resources/canvas-tests.js"); + +var t = async_test("check that the state is reset"); +var t_pass = t.done.bind(t); +var t_fail = t.step_func(function(reason) { + throw reason; +}); +t.step(function() { + + var canvas = new OffscreenCanvas(100, 50); + var ctx = canvas.getContext('2d'); + + const default_value = ctx.shadowOffsetY; + + ctx.shadowOffsetY = 10.0; + _assert(ctx.shadowOffsetY == 10.0, "ctx.shadowOffsetY == 10.0"); + + ctx.reset(); + _assert(ctx.shadowOffsetY == default_value, "ctx.shadowOffsetY == default_value"); + t.done(); +}); +done(); diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.stroke_style.html b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.stroke_style.html new file mode 100644 index 0000000000..79803b2828 --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.stroke_style.html @@ -0,0 +1,33 @@ + + +OffscreenCanvas test: 2d.reset.state.stroke_style + + + + +

2d.reset.state.stroke_style

+

check that the state is reset

+ + + diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.stroke_style.worker.js b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.stroke_style.worker.js new file mode 100644 index 0000000000..99e1eaaed5 --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.stroke_style.worker.js @@ -0,0 +1,28 @@ +// DO NOT EDIT! This test has been generated by /html/canvas/tools/gentest.py. +// OffscreenCanvas test in a worker:2d.reset.state.stroke_style +// Description:check that the state is reset +// Note: + +importScripts("/resources/testharness.js"); +importScripts("/html/canvas/resources/canvas-tests.js"); + +var t = async_test("check that the state is reset"); +var t_pass = t.done.bind(t); +var t_fail = t.step_func(function(reason) { + throw reason; +}); +t.step(function() { + + var canvas = new OffscreenCanvas(100, 50); + var ctx = canvas.getContext('2d'); + + const default_value = ctx.strokeStyle; + + ctx.strokeStyle = '#ffffff'; + _assert(ctx.strokeStyle == '#ffffff', "ctx.strokeStyle == '#ffffff'"); + + ctx.reset(); + _assert(ctx.strokeStyle == default_value, "ctx.strokeStyle == default_value"); + t.done(); +}); +done(); diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.text_align.html b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.text_align.html new file mode 100644 index 0000000000..c1a33d6f3d --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.text_align.html @@ -0,0 +1,33 @@ + + +OffscreenCanvas test: 2d.reset.state.text_align + + + + +

2d.reset.state.text_align

+

check that the state is reset

+ + + diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.text_align.worker.js b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.text_align.worker.js new file mode 100644 index 0000000000..087d3195e4 --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.text_align.worker.js @@ -0,0 +1,28 @@ +// DO NOT EDIT! This test has been generated by /html/canvas/tools/gentest.py. +// OffscreenCanvas test in a worker:2d.reset.state.text_align +// Description:check that the state is reset +// Note: + +importScripts("/resources/testharness.js"); +importScripts("/html/canvas/resources/canvas-tests.js"); + +var t = async_test("check that the state is reset"); +var t_pass = t.done.bind(t); +var t_fail = t.step_func(function(reason) { + throw reason; +}); +t.step(function() { + + var canvas = new OffscreenCanvas(100, 50); + var ctx = canvas.getContext('2d'); + + const default_value = ctx.textAlign; + + ctx.textAlign = 'end'; + _assert(ctx.textAlign == 'end', "ctx.textAlign == 'end'"); + + ctx.reset(); + _assert(ctx.textAlign == default_value, "ctx.textAlign == default_value"); + t.done(); +}); +done(); diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.text_baseline.html b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.text_baseline.html new file mode 100644 index 0000000000..acb56e4a00 --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.text_baseline.html @@ -0,0 +1,33 @@ + + +OffscreenCanvas test: 2d.reset.state.text_baseline + + + + +

2d.reset.state.text_baseline

+

check that the state is reset

+ + + diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.text_baseline.worker.js b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.text_baseline.worker.js new file mode 100644 index 0000000000..9a171326cb --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.text_baseline.worker.js @@ -0,0 +1,28 @@ +// DO NOT EDIT! This test has been generated by /html/canvas/tools/gentest.py. +// OffscreenCanvas test in a worker:2d.reset.state.text_baseline +// Description:check that the state is reset +// Note: + +importScripts("/resources/testharness.js"); +importScripts("/html/canvas/resources/canvas-tests.js"); + +var t = async_test("check that the state is reset"); +var t_pass = t.done.bind(t); +var t_fail = t.step_func(function(reason) { + throw reason; +}); +t.step(function() { + + var canvas = new OffscreenCanvas(100, 50); + var ctx = canvas.getContext('2d'); + + const default_value = ctx.textBaseline; + + ctx.textBaseline = 'middle'; + _assert(ctx.textBaseline == 'middle', "ctx.textBaseline == 'middle'"); + + ctx.reset(); + _assert(ctx.textBaseline == default_value, "ctx.textBaseline == default_value"); + t.done(); +}); +done(); diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.text_rendering.html b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.text_rendering.html new file mode 100644 index 0000000000..174dbb3801 --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.text_rendering.html @@ -0,0 +1,33 @@ + + +OffscreenCanvas test: 2d.reset.state.text_rendering + + + + +

2d.reset.state.text_rendering

+

check that the state is reset

+ + + diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.text_rendering.worker.js b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.text_rendering.worker.js new file mode 100644 index 0000000000..df4cea1044 --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.text_rendering.worker.js @@ -0,0 +1,28 @@ +// DO NOT EDIT! This test has been generated by /html/canvas/tools/gentest.py. +// OffscreenCanvas test in a worker:2d.reset.state.text_rendering +// Description:check that the state is reset +// Note: + +importScripts("/resources/testharness.js"); +importScripts("/html/canvas/resources/canvas-tests.js"); + +var t = async_test("check that the state is reset"); +var t_pass = t.done.bind(t); +var t_fail = t.step_func(function(reason) { + throw reason; +}); +t.step(function() { + + var canvas = new OffscreenCanvas(100, 50); + var ctx = canvas.getContext('2d'); + + const default_value = ctx.textRendering; + + ctx.textRendering = 'geometricPrecision'; + _assert(ctx.textRendering == 'geometricPrecision', "ctx.textRendering == 'geometricPrecision'"); + + ctx.reset(); + _assert(ctx.textRendering == default_value, "ctx.textRendering == default_value"); + t.done(); +}); +done(); diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.transformation_matrix.html b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.transformation_matrix.html new file mode 100644 index 0000000000..c30e459b30 --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.transformation_matrix.html @@ -0,0 +1,30 @@ + + +OffscreenCanvas test: 2d.reset.state.transformation_matrix + + + + +

2d.reset.state.transformation_matrix

+

check that the state is reset

+ + + diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.transformation_matrix.worker.js b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.transformation_matrix.worker.js new file mode 100644 index 0000000000..2ae105c20e --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.transformation_matrix.worker.js @@ -0,0 +1,25 @@ +// DO NOT EDIT! This test has been generated by /html/canvas/tools/gentest.py. +// OffscreenCanvas test in a worker:2d.reset.state.transformation_matrix +// Description:check that the state is reset +// Note: + +importScripts("/resources/testharness.js"); +importScripts("/html/canvas/resources/canvas-tests.js"); + +var t = async_test("check that the state is reset"); +var t_pass = t.done.bind(t); +var t_fail = t.step_func(function(reason) { + throw reason; +}); +t.step(function() { + + var canvas = new OffscreenCanvas(100, 50); + var ctx = canvas.getContext('2d'); + + ctx.scale(2, 2); + + ctx.reset(); + _assert(ctx.getTransform().isIdentity, "ctx.getTransform().isIdentity"); + t.done(); +}); +done(); diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.word_spacing.html b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.word_spacing.html new file mode 100644 index 0000000000..470db2cf98 --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.word_spacing.html @@ -0,0 +1,33 @@ + + +OffscreenCanvas test: 2d.reset.state.word_spacing + + + + +

2d.reset.state.word_spacing

+

check that the state is reset

+ + + diff --git a/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.word_spacing.worker.js b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.word_spacing.worker.js new file mode 100644 index 0000000000..9e8c717f78 --- /dev/null +++ b/testing/web-platform/tests/html/canvas/offscreen/reset/2d.reset.state.word_spacing.worker.js @@ -0,0 +1,28 @@ +// DO NOT EDIT! This test has been generated by /html/canvas/tools/gentest.py. +// OffscreenCanvas test in a worker:2d.reset.state.word_spacing +// Description:check that the state is reset +// Note: + +importScripts("/resources/testharness.js"); +importScripts("/html/canvas/resources/canvas-tests.js"); + +var t = async_test("check that the state is reset"); +var t_pass = t.done.bind(t); +var t_fail = t.step_func(function(reason) { + throw reason; +}); +t.step(function() { + + var canvas = new OffscreenCanvas(100, 50); + var ctx = canvas.getContext('2d'); + + const default_value = ctx.wordSpacing; + + ctx.wordSpacing = '12px'; + _assert(ctx.wordSpacing == '12px', "ctx.wordSpacing == '12px'"); + + ctx.reset(); + _assert(ctx.wordSpacing == default_value, "ctx.wordSpacing == default_value"); + t.done(); +}); +done(); -- cgit v1.2.3