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

Side by Side Diff: third_party/WebKit/LayoutTests/svg/css/svgcursorelement-use-counter.html

Issue 2376613004: Add use counters for SVGCursorElement (Closed)
Patch Set: Add test Created 4 years, 2 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
OLDNEW
(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>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698