Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1)

Unified Diff: third_party/WebKit/LayoutTests/fast/canvas/OffscreenCanvas-commit-promise.html

Issue 2594843002: Implementing promise-based commit for driving OffscreenCanvas animations (Closed)
Patch Set: rebase Created 3 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/LayoutTests/fast/canvas/OffscreenCanvas-commit-promise.html
diff --git a/third_party/WebKit/LayoutTests/fast/canvas/OffscreenCanvas-commit-promise.html b/third_party/WebKit/LayoutTests/fast/canvas/OffscreenCanvas-commit-promise.html
new file mode 100644
index 0000000000000000000000000000000000000000..6cce28798d93563528c45307bbc520901e2254ad
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/fast/canvas/OffscreenCanvas-commit-promise.html
@@ -0,0 +1,19 @@
+<!DOCTYPE html>
+<script src="../../resources/testharness.js"></script>
+<script src="../../resources/testharnessreport.js"></script>
+<script>
+promise_test(t => {
+ var canvas = document.createElement('canvas');
+ var offscreen = canvas.transferControlToOffscreen();
+ var ctx = offscreen.getContext('2d');
+ return ctx.commit();
+}, "Verify that the promise returned by a 2d context's commit() gets resolved.");
+
+promise_test(t => {
+ var canvas = document.createElement('canvas');
+ var offscreen = canvas.transferControlToOffscreen();
+ var ctx = offscreen.getContext('webgl');
+ return ctx.commit();
+}, "Verify that the promise returned by a webgl context's commit gets resolved.");
+
+</script>

Powered by Google App Engine
This is Rietveld 408576698