| Index: third_party/WebKit/LayoutTests/svg/animations/end-use-counters.html
|
| diff --git a/third_party/WebKit/LayoutTests/svg/animations/end-use-counters.html b/third_party/WebKit/LayoutTests/svg/animations/end-use-counters.html
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..daa11c01d09b9c8ce1a08f59cdef63d1e3a5024c
|
| --- /dev/null
|
| +++ b/third_party/WebKit/LayoutTests/svg/animations/end-use-counters.html
|
| @@ -0,0 +1,41 @@
|
| +<!DOCTYPE html>
|
| +<script src="../../resources/testharness.js"></script>
|
| +<script src="../../resources/testharnessreport.js"></script>
|
| +<svg width="400" height="400">
|
| + <rect id="target" x="10" y="10" width="80" height="80" />
|
| +</svg>
|
| +<script>
|
| +'use strict';
|
| +
|
| +// From UseCounter.h
|
| +var SVGEventValue = 1440;
|
| +var SVGSyncbaseValue = 1441;
|
| +
|
| +test(() => {
|
| + var target = document.getElementById('target');
|
| + var animation = document.createElementNS("http://www.w3.org/2000/svg", "animate");
|
| + animation.setAttribute("end", "5s;7s");
|
| + target.appendChild(animation);
|
| + assert_false(internals.isUseCounted(document, SVGEventValue));
|
| + assert_false(internals.isUseCounted(document, SVGSyncbaseValue));
|
| +}, 'end list using time is not counted as event or syncbase value.');
|
| +
|
| +test(() => {
|
| + var target = document.getElementById('target');
|
| + assert_false(internals.isUseCounted(document, SVGSyncbaseValue));
|
| + var animation = document.createElementNS("http://www.w3.org/2000/svg", "animate");
|
| + animation.setAttribute("end", "anim.begin - 5s;15s");
|
| + target.appendChild(animation);
|
| + assert_true(internals.isUseCounted(document, SVGSyncbaseValue));
|
| +}, 'end list using syncbase-value is use counted.');
|
| +
|
| +test(() => {
|
| + var target = document.getElementById('target');
|
| + assert_false(internals.isUseCounted(document, SVGEventValue));
|
| + var animation = document.createElementNS("http://www.w3.org/2000/svg", "animate");
|
| + animation.setAttribute("end", "0s;anim.repeatEvent-4s;5s");
|
| + target.appendChild(animation);
|
| + assert_true(internals.isUseCounted(document, SVGEventValue));
|
| +}, 'end list using event-value is use counted.');
|
| +
|
| +</script>
|
|
|