OLD | NEW |
(Empty) | |
| 1 <!DOCTYPE html> |
| 2 <title>SVGCursorElement use counters</title> |
| 3 <script src="../../resources/testharness.js"></script> |
| 4 <script src="../../resources/testharnessreport.js"></script> |
| 5 <style> |
| 6 #target { |
| 7 cursor: url(#mycursor), auto; |
| 8 } |
| 9 </style> |
| 10 <script> |
| 11 // From UseCounter.h |
| 12 const SVGCursorElement = 1587; |
| 13 const SVGCursorElementHasClient = 1588; |
| 14 |
| 15 test(function() { |
| 16 assert_false(internals.isUseCounted(document, SVGCursorElement)); |
| 17 assert_false(internals.isUseCounted(document, SVGCursorElementHasClient)); |
| 18 }, document.title + ', before element parsed'); |
| 19 </script> |
| 20 <svg><cursor id="mycursor" href="data:image/png;base64,"></cursor></svg> |
| 21 <script> |
| 22 test(function() { |
| 23 assert_true(internals.isUseCounted(document, SVGCursorElement)); |
| 24 assert_false(internals.isUseCounted(document, SVGCursorElementHasClient)); |
| 25 }, document.title + ', after element parsed'); |
| 26 </script> |
| 27 <svg id="target"></svg> |
| 28 <script> |
| 29 test(function() { |
| 30 document.querySelector('#target').clientLeft; |
| 31 |
| 32 assert_true(internals.isUseCounted(document, SVGCursorElement)); |
| 33 assert_true(internals.isUseCounted(document, SVGCursorElementHasClient)); |
| 34 }, document.title + ', after style computed'); |
| 35 </script> |
OLD | NEW |