OLD | NEW |
1 <!DOCTYPE html> | 1 <!DOCTYPE html> |
2 <div id="container"></div> | 2 <div id="container"></div> |
3 <script src="../../fast/workers/resources/worker-util.js"></script> | 3 <script src="../../../../fast/workers/resources/worker-util.js"></script> |
4 <script src="../../resources/testharness.js"></script> | 4 <script src="../../../../resources/testharness.js"></script> |
5 <script src="../../resources/testharnessreport.js"></script> | 5 <script src="../../../../resources/testharnessreport.js"></script> |
6 <script> | 6 <script> |
7 | 7 |
8 var test = async_test(function() { | 8 var test = async_test(function() { |
9 assert_not_equals('undefined', typeof window.internals); | 9 assert_not_equals('undefined', typeof window.internals); |
10 var worker = new CompositorWorker('resources/proxy-idle.js'); | 10 var worker = new CompositorWorker('resources/proxy-idle.js'); |
11 worker.onmessage = function() { | 11 worker.onmessage = function() { |
12 var docLayer = JSON.parse(window.internals.layerTreeAsText(document)); | 12 var docLayer = JSON.parse(window.internals.layerTreeAsText(document)); |
13 assert_equals(1, docLayer.children.length); | 13 assert_equals(1, docLayer.children.length); |
14 assert_equals(1, docLayer.children[0].children.length); | 14 assert_equals(1, docLayer.children[0].children.length); |
15 | 15 |
(...skipping 12 matching lines...) Expand all Loading... |
28 worker.postMessage(proxy); | 28 worker.postMessage(proxy); |
29 | 29 |
30 var container = document.getElementById('container'); | 30 var container = document.getElementById('container'); |
31 var docLayer = JSON.parse(window.internals.layerTreeAsText(document)); | 31 var docLayer = JSON.parse(window.internals.layerTreeAsText(document)); |
32 assert_equals(1, docLayer.children.length); | 32 assert_equals(1, docLayer.children.length); |
33 assert_equals(1, docLayer.children[0].children.length); | 33 assert_equals(1, docLayer.children[0].children.length); |
34 proxy.disconnect(); | 34 proxy.disconnect(); |
35 }, "This test checks that an element's compositor proxy cannot be mutated after
disconnect()."); | 35 }, "This test checks that an element's compositor proxy cannot be mutated after
disconnect()."); |
36 | 36 |
37 </script> | 37 </script> |
OLD | NEW |