mirror of
https://github.com/servo/servo.git
synced 2025-08-15 10:25:32 +01:00
Update web-platform-tests to revision ee82278e15570e573d87fb80179ff8231b6db61a
This commit is contained in:
parent
d23bc4f1a4
commit
83e2dc11b0
278 changed files with 13348 additions and 10515 deletions
|
@ -9,18 +9,18 @@
|
|||
<style>
|
||||
@keyframes outline-anim {
|
||||
from {
|
||||
outline: solid 1px rgb(1,0,0);
|
||||
outline: solid 1px rgba(1, 0, 0, 0.5);
|
||||
outline-offset: 1px;
|
||||
}
|
||||
to {
|
||||
outline: solid 3px rgb(3,0,0);
|
||||
outline: solid 3px rgba(3, 0, 0, 0.5);
|
||||
outline-offset: 3px;
|
||||
}
|
||||
}
|
||||
|
||||
#test {
|
||||
animation: outline-anim 3s -1.5s paused linear;
|
||||
outline: solid 1px rgb(1,0,0);
|
||||
outline: solid 1px rgba(1, 0, 0, 0.5);
|
||||
outline-offset: 1px;
|
||||
}
|
||||
</style>
|
||||
|
@ -29,20 +29,27 @@
|
|||
<div id=log></div>
|
||||
|
||||
<script>
|
||||
test(
|
||||
function(){
|
||||
var test = document.getElementById("test");
|
||||
assert_equals(getComputedStyle(test).outlineColor, 'rgb(2, 0, 0)');
|
||||
}, "outline-color is animated as a color");
|
||||
test(
|
||||
function(){
|
||||
var test = document.getElementById("test");
|
||||
assert_equals(getComputedStyle(test).outlineWidth, '2px');
|
||||
}, "outline-width is animated as a length");
|
||||
test(
|
||||
function(){
|
||||
var test = document.getElementById("test");
|
||||
assert_equals(getComputedStyle(test).outlineOffset, '2px');
|
||||
}, "outline-offset is animated as a length");
|
||||
// outline being a render-only property, its animation can be done off the main thread
|
||||
// checking the values after the first paint is safer, hence requestAnimationFrame
|
||||
setup({explicit_done:true});
|
||||
requestAnimationFrame(function() {
|
||||
// synchronous tests being run during the page's first paint
|
||||
test(
|
||||
function(){
|
||||
var test = document.getElementById("test");
|
||||
assert_equals(getComputedStyle(test).outlineColor, 'rgba(2, 0, 0, 0.5)');
|
||||
}, "outline-color is animated as a color");
|
||||
test(
|
||||
function(){
|
||||
var test = document.getElementById("test");
|
||||
assert_equals(getComputedStyle(test).outlineWidth, '2px');
|
||||
}, "outline-width is animated as a length");
|
||||
test(
|
||||
function(){
|
||||
var test = document.getElementById("test");
|
||||
assert_equals(getComputedStyle(test).outlineOffset, '2px');
|
||||
}, "outline-offset is animated as a length");
|
||||
done();
|
||||
});
|
||||
</script>
|
||||
</body>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue