37 lines
931 B
HTML
37 lines
931 B
HTML
<!DOCTYPE html>
|
|
<html>
|
|
<head>
|
|
<style>
|
|
#box {
|
|
position: absolute;
|
|
left: 0;
|
|
top: 100px;
|
|
height: 100px;
|
|
width: 100px;
|
|
background-color: red;
|
|
-webkit-animation-duration: 1s;
|
|
-webkit-animation-timing-function: linear;
|
|
-webkit-animation-iteration-count: infinite;
|
|
-webkit-animation-name: "anim";
|
|
}
|
|
@-webkit-keyframes "anim" {
|
|
from { left: 0px; }
|
|
to { left: 100px; }
|
|
}
|
|
</style>
|
|
<script src="resources/animation-test-helpers.js" type="text/javascript" charset="utf-8"></script>
|
|
<script type="text/javascript" charset="utf-8">
|
|
const expectedValues = [
|
|
// [animation-name, time, element-id, property, expected-value, tolerance]
|
|
["anim", 2.5, "box", "left", 50, 5],
|
|
];
|
|
|
|
runAnimationTest(expectedValues);
|
|
</script>
|
|
</head>
|
|
<body>
|
|
<div id="box"></div>
|
|
<div id="result"></div>
|
|
</body>
|
|
</html>
|