Index: third_party/WebKit/LayoutTests/fast/canvas/OffscreenCanvas-getContext-in-worker.js |
diff --git a/third_party/WebKit/LayoutTests/fast/canvas/OffscreenCanvas-getContext-in-worker.js b/third_party/WebKit/LayoutTests/fast/canvas/OffscreenCanvas-getContext-in-worker.js |
new file mode 100644 |
index 0000000000000000000000000000000000000000..aaaaf60cf3bbf364a83370e72385d534caca2c79 |
--- /dev/null |
+++ b/third_party/WebKit/LayoutTests/fast/canvas/OffscreenCanvas-getContext-in-worker.js |
@@ -0,0 +1,10 @@ |
+importScripts("../../resources/testharness.js"); |
fs
2016/08/25 08:14:58
Could possibly put this file in a resources/ or sc
|
+test(function() { |
+ var aCanvas = new OffscreenCanvas(50, 50); |
+ var bCanvas = new OffscreenCanvas(50, 50); |
+ var ctx1 = aCanvas.getContext('2d'); |
+ var ctx2 = bCanvas.getContext('webgl'); |
+ assert_true(ctx1 instanceof OffscreenCanvasRenderingContext2D); |
+ assert_true(ctx2 instanceof WebGLRenderingContext); |
+}); |
+done(); |