blob: 9f26cef97b56e69708346ff5d1d88281ef6a465c [file] [log] [blame]
<!DOCTYPE html>
<script src="../../resources/testharness.js"></script>
<script src="../../resources/testharnessreport.js"></script>
<div id="target"></div>
<script>
test(() => {
var firstAnimation = target.animate([{visibility: 'hidden'}, {visibility: 'visible'}], 1);
var secondAnimation = target.animate({visibility: 'collapse'}, 1);
firstAnimation.pause();
firstAnimation.currentTime = 0;
secondAnimation.pause();
secondAnimation.currentTime = 0.75;
assert_equals(getComputedStyle(target).visibility, 'collapse');
firstAnimation.currentTime = 0.1;
assert_equals(getComputedStyle(target).visibility, 'visible');
}, "Visibility animations with neutral keyframes should be responsive to animations they're stacked on top of.");
</script>