mirror of
https://github.com/servo/servo.git
synced 2025-08-14 09:55:35 +01:00
Update web-platform-tests to revision ab64b78a8f6777a1d95d8d1d4bba9ccdbecf94ea
This commit is contained in:
parent
da36740f0b
commit
394aced19f
713 changed files with 12430 additions and 12632 deletions
|
@ -1,7 +1,7 @@
|
|||
<!DOCTYPE html>
|
||||
<title>Reference for Fieldset and transform: translateZ(0)</title>
|
||||
<style>
|
||||
fieldset { background: #eee; }
|
||||
fieldset { background: #eee; margin: 0 0 10px; }
|
||||
</style>
|
||||
<p>It should say PASS below without anything obscuring the text.</p>
|
||||
|
||||
|
|
|
@ -0,0 +1,46 @@
|
|||
<!doctype html>
|
||||
<title>legend align</title>
|
||||
<script src=/resources/testharness.js></script>
|
||||
<script src=/resources/testharnessreport.js></script>
|
||||
<fieldset><legend align=left>x</legend></fieldset>
|
||||
<fieldset><legend align=center>x</legend></fieldset>
|
||||
<fieldset><legend align=right>x</legend></fieldset>
|
||||
<div align=left>
|
||||
<fieldset><legend>x</legend></fieldset>
|
||||
</div>
|
||||
<div align=center>
|
||||
<fieldset><legend>x</legend></fieldset>
|
||||
</div>
|
||||
<div align=right>
|
||||
<fieldset><legend>x</legend></fieldset>
|
||||
</div>
|
||||
<div style="text-align: center">
|
||||
<fieldset><legend>x</legend></fieldset>
|
||||
</div>
|
||||
<div style="text-align: center" align=center>
|
||||
<fieldset><legend>x</legend></fieldset>
|
||||
</div>
|
||||
<fieldset><legend style="margin: 0 auto">x</legend></fieldset>
|
||||
<fieldset><legend style="margin: 0 0 0 auto">x</legend></fieldset>
|
||||
<fieldset dir=rtl><legend>x</legend></fieldset>
|
||||
<fieldset dir=rtl><legend style="text-align: left">x</legend></fieldset>
|
||||
<script>
|
||||
function test_align(selectorTest, selectorRef) {
|
||||
const testElm = document.querySelector(selectorTest);
|
||||
const refElm = document.querySelector(selectorRef);
|
||||
test(() => {
|
||||
assert_equals(testElm.offsetLeft, refElm.offsetLeft, `expected ${selectorRef}`);
|
||||
}, selectorTest);
|
||||
}
|
||||
|
||||
for (const val of ['left', 'center', 'right']) {
|
||||
test_align(`div[align=${val}] legend`, `legend[align=${val}]`);
|
||||
}
|
||||
|
||||
test_align(`div[style="text-align: center"] legend`, `legend[align=left]`);
|
||||
test_align(`div[style="text-align: center"][align=center] legend`, `legend[align=center]`);
|
||||
test_align(`legend[style="margin: 0 auto"]`, `legend[align=center]`);
|
||||
test_align(`legend[style="margin: 0 0 0 auto"]`, `legend[align=right]`);
|
||||
test_align(`fieldset[dir=rtl] legend`, `legend[align=right]`);
|
||||
test_align(`fieldset[dir=rtl] legend[style="text-align: left"]`, `legend[align=right]`);
|
||||
</script>
|
|
@ -0,0 +1,19 @@
|
|||
<!DOCTYPE html>
|
||||
<html class=reftest-wait>
|
||||
<title>legend and dynamic update</title>
|
||||
<link rel=fieldset-foo-ref.html>
|
||||
<p>There should be a normal fieldset below with the legend "Foo".</p>
|
||||
<fieldset>
|
||||
<legend>F</legend>
|
||||
</fieldset>
|
||||
<script>
|
||||
const legend = document.querySelector('legend');
|
||||
// force layout
|
||||
legend.offsetTop;
|
||||
requestAnimationFrame(() => {
|
||||
legend.textContent += "oo";
|
||||
requestAnimationFrame(() => {
|
||||
document.documentElement.removeAttribute('class');
|
||||
});
|
||||
});
|
||||
</script>
|
|
@ -3,7 +3,7 @@
|
|||
<link rel=match href=legend-position-relative-ref.html>
|
||||
<style>
|
||||
fieldset { border: 100px solid lime; width: 200px; padding: 0; margin: 0 }
|
||||
legend { position: relative; left: 100px; width: 100px; padding: 0 }
|
||||
legend { position: relative; left: 100px; width: 100px; height: 100px; padding: 0 }
|
||||
.behind { position: absolute; left: 208px; width: 100px; height: 100px; background: red; z-index: -1 }
|
||||
</style>
|
||||
<p>There should be no red.</p>
|
||||
|
|
|
@ -39,7 +39,7 @@ onload = function() {
|
|||
var expected = {wide:resolve(img.dataset.wide), narrow:resolve(img.dataset.narrow)};
|
||||
var current = iframe.className;
|
||||
var next = current === 'wide' ? 'narrow' : 'wide';
|
||||
var expect_change = expected[next].indexOf('broken.png') !== 0 && !('noChange' in img.dataset);
|
||||
var expect_change = expected[next].indexOf('broken.png') === -1 && !('noChange' in img.dataset);
|
||||
|
||||
test(function() {
|
||||
assert_equals(img.currentSrc, expected[current]);
|
||||
|
|
|
@ -3,7 +3,7 @@ test(t => {
|
|||
t.add_cleanup(() => frame.remove());
|
||||
assert_equals(frame.contentDocument.URL, "about:blank");
|
||||
assert_equals(frame.contentWindow.location.href, "about:blank");
|
||||
frame.contentDocument.open();
|
||||
assert_equals(frame.contentDocument.open(), frame.contentDocument);
|
||||
assert_equals(frame.contentDocument.URL, document.URL);
|
||||
assert_equals(frame.contentWindow.location.href, document.URL);
|
||||
}, "document.open() changes document's URL (fully active document)");
|
||||
|
@ -26,7 +26,7 @@ async_test(t => {
|
|||
|
||||
frame.onload = t.step_func_done(() => {
|
||||
// Now childDoc is still active but no longer fully active.
|
||||
childDoc.open();
|
||||
assert_equals(childDoc.open(), childDoc);
|
||||
assert_equals(childDoc.URL, blankURL);
|
||||
assert_equals(childWin.location.href, blankURL);
|
||||
});
|
||||
|
@ -40,6 +40,9 @@ test(t => {
|
|||
t.add_cleanup(() => frame.remove());
|
||||
const doc = frame.contentDocument;
|
||||
|
||||
// We do not test for win.location.href in this test due to
|
||||
// https://github.com/whatwg/html/issues/3959.
|
||||
|
||||
// Right now the frame is connected and it has an active document.
|
||||
assert_equals(doc.URL, "about:blank");
|
||||
|
||||
|
@ -55,6 +58,9 @@ async_test(t => {
|
|||
const frame = document.createElement("iframe");
|
||||
t.add_cleanup(() => frame.remove());
|
||||
|
||||
// We do not test for win.location.href in this test due to
|
||||
// https://github.com/whatwg/html/issues/3959.
|
||||
|
||||
frame.onload = t.step_func(() => {
|
||||
const doc = frame.contentDocument;
|
||||
// Right now the frame is connected and it has an active document.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue