summaryrefslogtreecommitdiffstats
path: root/dom/animation/test/css-animations/file_animation-id.html
blob: dbd5ee0eef37e5232c53a5057c7d1dc5325a2a55 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
<!doctype html>
<meta charset=utf-8>
<script src="../testcommon.js"></script>
<style>
@keyframes abc { }
</style>
<body>
<script>
'use strict';

test(function(t) {
  var div = addDiv(t);
  div.style.animation = 'abc 100s';
  var animation = div.getAnimations()[0];
  assert_equals(animation.id, '', 'id for CSS Animation is initially empty');
  animation.id = 'anim'

  assert_equals(animation.id, 'anim', 'animation.id reflects the value set');
}, 'Animation.id for CSS Animations');

done();
</script>
</body>
</html>