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

Side by Side Diff: third_party/WebKit/LayoutTests/fast/canvas/canvas-context-gc-custom-properties.html

Issue 2818563004: sendBeacon should throw a TypeError on bad URLs. (Closed)
Patch Set: Patch Set 2 was the final submit, 3 was uploaded by mistake. Created 3 years, 7 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 unified diff | Download patch
« no previous file with comments | « no previous file | third_party/WebKit/LayoutTests/fast/canvas/webgl/context-destroyed-crash.html » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 <script src="../../resources/testharness.js"></script> 1 <script src="../../resources/testharness.js"></script>
2 <script src="../../resources/testharnessreport.js"></script> 2 <script src="../../resources/testharnessreport.js"></script>
3 <script src="../../resources/gc.js"></script>
3 <script> 4 <script>
4 function gc() {
5 if (typeof GCController !== "undefined")
6 GCController.collectAll();
7 else {
8 var gcRec = function (n) {
9 if (n < 1)
10 return {};
11 var temp = {i: "ab" + i + (i / 100000)};
12 temp += "foo";
13 gcRec(n-1);
14 };
15 for (var i = 0; i < 1000; i++)
16 gcRec(10);
17 }
18 }
19 5
20 function runTest() { 6 function runTest() {
21 canvas = document.createElement("canvas"); 7 canvas = document.createElement("canvas");
22 context = canvas.getContext("2d"); 8 context = canvas.getContext("2d");
23 context.customProperty = "value"; 9 context.customProperty = "value";
24 assert_equals(context.customProperty, "value"); 10 assert_equals(context.customProperty, "value");
25 context = null; 11 context = null;
26 gc(); 12 gc();
27 context = canvas.getContext("2d"); 13 context = canvas.getContext("2d");
28 assert_equals(context.customProperty, "value"); 14 assert_equals(context.customProperty, "value");
29 } 15 }
30 16
31 async_test(t => { 17 async_test(t => {
32 window.onload = function() { 18 window.onload = function() {
33 t.step(runTest); 19 t.step(runTest);
34 t.done(); 20 t.done();
35 } 21 }
36 }, 'Verify that the custom properties on a Canvas 2D rendering context object ar e retained across GCs.'); 22 }, 'Verify that the custom properties on a Canvas 2D rendering context object ar e retained across GCs.');
37 23
38 </script> 24 </script>
OLDNEW
« no previous file with comments | « no previous file | third_party/WebKit/LayoutTests/fast/canvas/webgl/context-destroyed-crash.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698