mirror of
https://github.com/servo/servo.git
synced 2025-08-03 04:30:10 +01:00
Update web-platform-tests to revision c0fbd59769588391d78838086bd02ad394301655
This commit is contained in:
parent
a07c718895
commit
a3df7c3a3c
105 changed files with 1922 additions and 1186 deletions
File diff suppressed because it is too large
Load diff
|
@ -38,3 +38,6 @@
|
|||
[Test @font-face matching for weight 249]
|
||||
expected: FAIL
|
||||
|
||||
[Test @font-face matching for weight 420]
|
||||
expected: FAIL
|
||||
|
||||
|
|
|
@ -0,0 +1,89 @@
|
|||
[request-bad-port.html]
|
||||
expected: TIMEOUT
|
||||
[Request on bad port 427 should throw TypeError.]
|
||||
expected: TIMEOUT
|
||||
|
||||
[Request on bad port 465 should throw TypeError.]
|
||||
expected: NOTRUN
|
||||
|
||||
[Request on bad port 512 should throw TypeError.]
|
||||
expected: NOTRUN
|
||||
|
||||
[Request on bad port 513 should throw TypeError.]
|
||||
expected: NOTRUN
|
||||
|
||||
[Request on bad port 514 should throw TypeError.]
|
||||
expected: NOTRUN
|
||||
|
||||
[Request on bad port 515 should throw TypeError.]
|
||||
expected: NOTRUN
|
||||
|
||||
[Request on bad port 526 should throw TypeError.]
|
||||
expected: NOTRUN
|
||||
|
||||
[Request on bad port 530 should throw TypeError.]
|
||||
expected: NOTRUN
|
||||
|
||||
[Request on bad port 531 should throw TypeError.]
|
||||
expected: NOTRUN
|
||||
|
||||
[Request on bad port 532 should throw TypeError.]
|
||||
expected: NOTRUN
|
||||
|
||||
[Request on bad port 540 should throw TypeError.]
|
||||
expected: NOTRUN
|
||||
|
||||
[Request on bad port 548 should throw TypeError.]
|
||||
expected: NOTRUN
|
||||
|
||||
[Request on bad port 556 should throw TypeError.]
|
||||
expected: NOTRUN
|
||||
|
||||
[Request on bad port 563 should throw TypeError.]
|
||||
expected: NOTRUN
|
||||
|
||||
[Request on bad port 587 should throw TypeError.]
|
||||
expected: NOTRUN
|
||||
|
||||
[Request on bad port 601 should throw TypeError.]
|
||||
expected: NOTRUN
|
||||
|
||||
[Request on bad port 636 should throw TypeError.]
|
||||
expected: NOTRUN
|
||||
|
||||
[Request on bad port 993 should throw TypeError.]
|
||||
expected: NOTRUN
|
||||
|
||||
[Request on bad port 995 should throw TypeError.]
|
||||
expected: NOTRUN
|
||||
|
||||
[Request on bad port 2049 should throw TypeError.]
|
||||
expected: NOTRUN
|
||||
|
||||
[Request on bad port 3659 should throw TypeError.]
|
||||
expected: NOTRUN
|
||||
|
||||
[Request on bad port 4045 should throw TypeError.]
|
||||
expected: NOTRUN
|
||||
|
||||
[Request on bad port 6000 should throw TypeError.]
|
||||
expected: NOTRUN
|
||||
|
||||
[Request on bad port 6665 should throw TypeError.]
|
||||
expected: NOTRUN
|
||||
|
||||
[Request on bad port 6666 should throw TypeError.]
|
||||
expected: NOTRUN
|
||||
|
||||
[Request on bad port 6667 should throw TypeError.]
|
||||
expected: NOTRUN
|
||||
|
||||
[Request on bad port 6668 should throw TypeError.]
|
||||
expected: NOTRUN
|
||||
|
||||
[Request on bad port 6669 should throw TypeError.]
|
||||
expected: NOTRUN
|
||||
|
||||
[Request on bad port 6697 should throw TypeError.]
|
||||
expected: NOTRUN
|
||||
|
|
@ -1,5 +0,0 @@
|
|||
[reload_post_1.html]
|
||||
type: testharness
|
||||
[Reload document with POST]
|
||||
expected: FAIL
|
||||
|
|
@ -1,6 +0,0 @@
|
|||
[sandbox-disallow-same-origin.html]
|
||||
type: testharness
|
||||
expected: ERROR
|
||||
[Access to sandbox iframe is disallowed]
|
||||
expected: NOTRUN
|
||||
|
7
tests/wpt/metadata/xhr/event-upload-progress.htm.ini
Normal file
7
tests/wpt/metadata/xhr/event-upload-progress.htm.ini
Normal file
|
@ -0,0 +1,7 @@
|
|||
[event-upload-progress.htm]
|
||||
[Upload events registered too late (http://www1.web-platform.test:8000/xhr/resources/corsenabled.py)]
|
||||
expected: FAIL
|
||||
|
||||
[Upload events registered too late (resources/redirect.py?code=307&location=http://www1.web-platform.test:8000/xhr/resources/corsenabled.py)]
|
||||
expected: FAIL
|
||||
|
|
@ -1,2 +0,0 @@
|
|||
[hide_after_load.html]
|
||||
expected: TIMEOUT
|
|
@ -1,5 +0,0 @@
|
|||
[rapid-resizing.html]
|
||||
expected: TIMEOUT
|
||||
[Overall test]
|
||||
expected: NOTRUN
|
||||
|
|
@ -1,5 +0,0 @@
|
|||
[context-creation-and-destruction.html]
|
||||
expected: TIMEOUT
|
||||
[Overall test]
|
||||
expected: NOTRUN
|
||||
|
|
@ -1,5 +0,0 @@
|
|||
[context-creation.html]
|
||||
expected: TIMEOUT
|
||||
[Overall test]
|
||||
expected: NOTRUN
|
||||
|
|
@ -1,2 +0,0 @@
|
|||
[context-eviction-with-garbage-collection.html]
|
||||
expected: TIMEOUT
|
|
@ -1,5 +0,0 @@
|
|||
[context-release-upon-reload.html]
|
||||
expected: TIMEOUT
|
||||
[Overall test]
|
||||
expected: NOTRUN
|
||||
|
|
@ -12,7 +12,7 @@ add_completion_callback(function(tests)
|
|||
if(tests[i].db)
|
||||
{
|
||||
tests[i].db.close();
|
||||
window.indexedDB.deleteDatabase(tests[i].db.name);
|
||||
self.indexedDB.deleteDatabase(tests[i].db.name);
|
||||
}
|
||||
}
|
||||
});
|
||||
|
@ -43,9 +43,9 @@ function createdb_for_multiple_tests(dbname, version) {
|
|||
dbname = (dbname ? dbname : "testdb-" + new Date().getTime() + Math.random() );
|
||||
|
||||
if (version)
|
||||
rq_open = window.indexedDB.open(dbname, version);
|
||||
rq_open = self.indexedDB.open(dbname, version);
|
||||
else
|
||||
rq_open = window.indexedDB.open(dbname);
|
||||
rq_open = self.indexedDB.open(dbname);
|
||||
|
||||
function auto_fail(evt, current_test) {
|
||||
/* Fail handlers, if we haven't set on/whatever/, don't
|
||||
|
@ -107,7 +107,7 @@ function assert_key_equals(actual, expected, description) {
|
|||
function indexeddb_test(upgrade_func, open_func, description, options) {
|
||||
async_test(function(t) {
|
||||
options = Object.assign({upgrade_will_abort: false}, options);
|
||||
var dbname = document.location + '-' + t.name;
|
||||
var dbname = location + '-' + t.name;
|
||||
var del = indexedDB.deleteDatabase(dbname);
|
||||
del.onerror = t.unreached_func('deleteDatabase should succeed');
|
||||
var open = indexedDB.open(dbname, 1);
|
||||
|
|
|
@ -9,13 +9,33 @@
|
|||
var subTestEnd = Infinity;
|
||||
var match;
|
||||
if (location.search) {
|
||||
match = /(?:^\?|&)(\d+)-(\d+|last)(?:&|$)/.exec(location.search);
|
||||
if (match) {
|
||||
subTestStart = parseInt(match[1], 10);
|
||||
if (match[2] !== "last") {
|
||||
subTestEnd = parseInt(match[2], 10);
|
||||
}
|
||||
match = /(?:^\?|&)(\d+)-(\d+|last)(?:&|$)/.exec(location.search);
|
||||
if (match) {
|
||||
subTestStart = parseInt(match[1], 10);
|
||||
if (match[2] !== "last") {
|
||||
subTestEnd = parseInt(match[2], 10);
|
||||
}
|
||||
}
|
||||
// Below is utility code to generate <meta> for copy/paste into tests.
|
||||
// Sample usage:
|
||||
// test.html?split=1000
|
||||
match = /(?:^\?|&)split=(\d+)(?:&|$)/.exec(location.search);
|
||||
if (match) {
|
||||
var testsPerVariant = parseInt(match[1], 10);
|
||||
add_completion_callback(tests => {
|
||||
var total = tests.length;
|
||||
var template = '<meta name="variant" content="?%s-%s">';
|
||||
var metas = [];
|
||||
for (var i = 1; i < total - testsPerVariant; i = i + testsPerVariant) {
|
||||
metas.push(template.replace("%s", i).replace("%s", i + testsPerVariant - 1));
|
||||
}
|
||||
metas.push(template.replace("%s", i).replace("%s", "last"));
|
||||
var pre = document.createElement('pre');
|
||||
pre.textContent = metas.join('\n');
|
||||
document.body.insertBefore(pre, document.body.firstChild);
|
||||
document.getSelection().selectAllChildren(pre);
|
||||
});
|
||||
}
|
||||
}
|
||||
function shouldRunSubTest(currentSubTest) {
|
||||
return currentSubTest >= subTestStart && currentSubTest <= subTestEnd;
|
||||
|
|
|
@ -0,0 +1,26 @@
|
|||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>Console Number Format Specifiers on Symbols</title>
|
||||
<meta name="author" title="Dominic Farolino" href="mailto:domfarolino@gmail.com">
|
||||
<meta name="assert" content="Console format specifiers on Symbols">
|
||||
<link rel="help" href="https://console.spec.whatwg.org/#formatter">
|
||||
</head>
|
||||
<body>
|
||||
<p>Open the console inside the developer tools. It should contain 15 lines, each of which are:</p>
|
||||
<p><code>NaN</code></p>
|
||||
|
||||
<script>
|
||||
const methods = ["log", "dirxml", "trace", "group", "groupCollapsed"];
|
||||
|
||||
for (method of methods) {
|
||||
console[method]("%i", Symbol.for("description"));
|
||||
if (method == "group" || method == "groupCollapsed") console.groupEnd();
|
||||
console[method]("%d", Symbol.for("description"));
|
||||
if (method == "group" || method == "groupCollapsed") console.groupEnd();
|
||||
console[method]("%f", Symbol.for("description"));
|
||||
if (method == "group" || method == "groupCollapsed") console.groupEnd();
|
||||
}
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
|
@ -1,7 +1,7 @@
|
|||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>Console Format Specifiers on Symbols</title>
|
||||
<title>Console String Format Specifier on Symbols</title>
|
||||
<meta name="author" title="Dominic Farolino" href="mailto:domfarolino@gmail.com">
|
||||
<meta name="assert" content="Console format specifiers on Symbols">
|
||||
<link rel="help" href="https://console.spec.whatwg.org/#formatter">
|
||||
|
@ -15,7 +15,9 @@ console.log("%s", Symbol.for("description"));
|
|||
console.dirxml("%s", Symbol.for("description"));
|
||||
console.trace("%s", Symbol.for("description"));
|
||||
console.group("%s", Symbol.for("description"));
|
||||
console.groupEnd();
|
||||
console.groupCollapsed("%s", Symbol.for("description"));
|
||||
console.groupEnd();
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
|
@ -4,6 +4,7 @@
|
|||
<meta http-equiv="content-type" content="text/html;charset=UTF-8"/>
|
||||
<title>WOFF Test: Font access</title>
|
||||
<link rel="author" title="Chris Lilley" href="http://www.w3.org/People" />
|
||||
<link rel="reviewer" title="Chris Lilley" href="mailto:chris@w3.org" />
|
||||
<link rel="help" href="http://dev.w3.org/webfonts/WOFF2/spec/#General" />
|
||||
<link rel="help" href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-css3font-available" />
|
||||
<meta name="assert" content="Linked fonts are only available to the documents that reference them." />
|
||||
|
|
30
tests/wpt/web-platform-tests/css/WOFF2/available-002.xht
Normal file
30
tests/wpt/web-platform-tests/css/WOFF2/available-002.xht
Normal file
|
@ -0,0 +1,30 @@
|
|||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||
<head>
|
||||
<meta http-equiv="content-type" content="text/html;charset=UTF-8"/>
|
||||
<title>WOFF Test: Font access</title>
|
||||
<link rel="author" title="Khaled Hosny" href="http://khaledhosny.org" />
|
||||
<link rel="reviewer" title="Chris Lilley" href="mailto:chris@w3.org" />
|
||||
<link rel="help" href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-mustLoadFontCollection" />
|
||||
<meta name="assert" content="Fonts must be loaded from font collections." />
|
||||
<style type="text/css"><![CDATA[
|
||||
body {
|
||||
font-size: 20px;
|
||||
}
|
||||
pre {
|
||||
font-size: 12px;
|
||||
}
|
||||
iframe {
|
||||
width: 24em;
|
||||
height: 300px;
|
||||
border: thin solid green
|
||||
}
|
||||
]]></style>
|
||||
</head>
|
||||
<body>
|
||||
<p>Test passes if the word PASS appears <em>twice</em> below, and the second one is condensed.</p>
|
||||
<iframe src="support/available-002a.xht" />
|
||||
<iframe src="support/available-002b.xht" />
|
||||
|
||||
</body>
|
||||
</html>
|
|
@ -2,12 +2,12 @@
|
|||
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||
<head>
|
||||
<meta http-equiv="content-type" content="text/html;charset=UTF-8"/>
|
||||
<title>WOFF Test: Decompressed Metadata Length Less Than metaOrigLength</title>
|
||||
<link rel="author" title="Tal Leming" href="http://typesupply.com" />
|
||||
<link rel="help" href="http://dev.w3.org/webfonts/WOFF2/spec/#Metadata" />
|
||||
<link rel="help" href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-metaOrigLength" />
|
||||
<title>WOFF Test: Valid SFNT With Cutsom Tag For Known Table</title>
|
||||
<link rel="author" title="Khaled Hosny" href="http://khaledhosny.org" />
|
||||
<link rel="help" href="http://dev.w3.org/webfonts/WOFF2/spec/#table_dir_format" />
|
||||
<link rel="help" href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-mayAcceptKnownTagsAsCustom" />
|
||||
<link rel="reviewer" title="Chris Lilley" href="mailto:chris@w3.org" />
|
||||
<meta name="assert" content="The metadata decompresses to a length that is 1 byte smaller than the length defined in metaOrigLength" />
|
||||
<meta name="assert" content="Valid TTF flavored SFNT font with table directory using custom tag instead of known table flag for some know tables." />
|
||||
<style type="text/css"><![CDATA[
|
||||
@import url("support/test-fonts.css");
|
||||
body {
|
||||
|
@ -24,8 +24,7 @@
|
|||
]]></style>
|
||||
</head>
|
||||
<body>
|
||||
<p>If the UA does not display WOFF metadata, the test passes if the word PASS appears below.</p>
|
||||
<p>The Extended Metadata Block is not valid and must not be displayed. If the UA does display it, the test fails.</p>
|
||||
<p>Test passes if the word PASS appears below.</p>
|
||||
<div class="test">P</div>
|
||||
</body>
|
||||
</html>
|
|
@ -2,18 +2,18 @@
|
|||
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||
<head>
|
||||
<meta http-equiv="content-type" content="text/html;charset=UTF-8"/>
|
||||
<title>WOFF Test: Decompressed Metadata Length Less Than metaOrigLength</title>
|
||||
<link rel="author" title="Tal Leming" href="http://typesupply.com" />
|
||||
<link rel="help" href="http://dev.w3.org/webfonts/WOFF2/spec/#Metadata" />
|
||||
<link rel="help" href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-metaOrigLength" />
|
||||
<title>WOFF Test: Valid SFNT With Cutsom Tag For Known Table</title>
|
||||
<link rel="author" title="Khaled Hosny" href="http://khaledhosny.org" />
|
||||
<link rel="help" href="http://dev.w3.org/webfonts/WOFF2/spec/#table_dir_format" />
|
||||
<link rel="help" href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-mayAcceptKnownTagsAsCustom" />
|
||||
<link rel="reviewer" title="Chris Lilley" href="mailto:chris@w3.org" />
|
||||
<link rel="match" href="metadatadisplay-metaOrigLength-001-ref.xht" />
|
||||
<meta name="assert" content="The metadata decompresses to a length that is 1 byte smaller than the length defined in metaOrigLength" />
|
||||
<link rel="match" href="directory-knowntags-001-ref.xht" />
|
||||
<meta name="assert" content="Valid TTF flavored SFNT font with table directory using custom tag instead of known table flag for some know tables." />
|
||||
<style type="text/css"><![CDATA[
|
||||
@import url("support/test-fonts.css");
|
||||
@font-face {
|
||||
font-family: "WOFF Test";
|
||||
src: url("support/metadatadisplay-metaOrigLength-001.woff2") format("woff2");
|
||||
src: url("support/directory-knowntags-001.woff2") format("woff2");
|
||||
}
|
||||
body {
|
||||
font-size: 20px;
|
||||
|
@ -29,8 +29,7 @@
|
|||
]]></style>
|
||||
</head>
|
||||
<body>
|
||||
<p>If the UA does not display WOFF metadata, the test passes if the word PASS appears below.</p>
|
||||
<p>The Extended Metadata Block is not valid and must not be displayed. If the UA does display it, the test fails.</p>
|
||||
<p>Test passes if the word PASS appears below.</p>
|
||||
<div class="test">P</div>
|
||||
</body>
|
||||
</html>
|
|
@ -1,32 +0,0 @@
|
|||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||
<head>
|
||||
<meta http-equiv="content-type" content="text/html;charset=UTF-8"/>
|
||||
<title>WOFF Test: Metadata No Compression</title>
|
||||
<link rel="author" title="Tal Leming" href="http://typesupply.com" />
|
||||
<link rel="help" href="http://dev.w3.org/webfonts/WOFF2/spec/#Metadata" />
|
||||
<link rel="help" href="http://dev.w3.org/webfonts/WOFF2/spec/" />
|
||||
<link rel="help" href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-metadata-alwayscompress" />
|
||||
<link rel="reviewer" title="Chris Lilley" href="mailto:chris@w3.org" />
|
||||
<meta name="assert" content="The metadata is stored in an uncompressed state and therefore does not have the proper compression format." />
|
||||
<style type="text/css"><![CDATA[
|
||||
@import url("support/test-fonts.css");
|
||||
body {
|
||||
font-size: 20px;
|
||||
}
|
||||
pre {
|
||||
font-size: 12px;
|
||||
}
|
||||
.test {
|
||||
font-family: "WOFF Test CFF Reference";
|
||||
font-size: 200px;
|
||||
margin-top: 50px;
|
||||
}
|
||||
]]></style>
|
||||
</head>
|
||||
<body>
|
||||
<p>If the UA does not display WOFF metadata, the test passes if the word PASS appears below.</p>
|
||||
<p>The Extended Metadata Block is not valid and must not be displayed. If the UA does display it, the test fails.</p>
|
||||
<div class="test">P</div>
|
||||
</body>
|
||||
</html>
|
|
@ -1,37 +0,0 @@
|
|||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||
<head>
|
||||
<meta http-equiv="content-type" content="text/html;charset=UTF-8"/>
|
||||
<title>WOFF Test: Metadata No Compression</title>
|
||||
<link rel="author" title="Tal Leming" href="http://typesupply.com" />
|
||||
<link rel="help" href="http://dev.w3.org/webfonts/WOFF2/spec/#Metadata" />
|
||||
<link rel="help" href="http://dev.w3.org/webfonts/WOFF2/spec/" />
|
||||
<link rel="help" href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-metadata-alwayscompress" />
|
||||
<link rel="reviewer" title="Chris Lilley" href="mailto:chris@w3.org" />
|
||||
<link rel="match" href="metadatadisplay-compression-001-ref.xht" />
|
||||
<meta name="assert" content="The metadata is stored in an uncompressed state and therefore does not have the proper compression format." />
|
||||
<style type="text/css"><![CDATA[
|
||||
@import url("support/test-fonts.css");
|
||||
@font-face {
|
||||
font-family: "WOFF Test";
|
||||
src: url("support/metadatadisplay-compression-001.woff2") format("woff2");
|
||||
}
|
||||
body {
|
||||
font-size: 20px;
|
||||
}
|
||||
pre {
|
||||
font-size: 12px;
|
||||
}
|
||||
.test {
|
||||
font-family: "WOFF Test", "WOFF Test CFF Fallback";
|
||||
font-size: 200px;
|
||||
margin-top: 50px;
|
||||
}
|
||||
]]></style>
|
||||
</head>
|
||||
<body>
|
||||
<p>If the UA does not display WOFF metadata, the test passes if the word PASS appears below.</p>
|
||||
<p>The Extended Metadata Block is not valid and must not be displayed. If the UA does display it, the test fails.</p>
|
||||
<div class="test">P</div>
|
||||
</body>
|
||||
</html>
|
|
@ -1,32 +0,0 @@
|
|||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||
<head>
|
||||
<meta http-equiv="content-type" content="text/html;charset=UTF-8"/>
|
||||
<title>WOFF Test: No id Attribute in uniqueid Element</title>
|
||||
<link rel="author" title="Tal Leming" href="http://typesupply.com" />
|
||||
<link rel="help" href="http://dev.w3.org/webfonts/WOFF2/spec/#Metadata" />
|
||||
<link rel="help" href="http://www.w3.org/TR/WOFF/#conform-metadata-noeffect" />
|
||||
<link rel="help" href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-metadata-id-required" />
|
||||
<link rel="reviewer" title="Chris Lilley" href="mailto:chris@w3.org" />
|
||||
<meta name="assert" content="The uniqueid element does not contain the required id attribute." />
|
||||
<style type="text/css"><![CDATA[
|
||||
@import url("support/test-fonts.css");
|
||||
body {
|
||||
font-size: 20px;
|
||||
}
|
||||
pre {
|
||||
font-size: 12px;
|
||||
}
|
||||
.test {
|
||||
font-family: "WOFF Test CFF Reference";
|
||||
font-size: 200px;
|
||||
margin-top: 50px;
|
||||
}
|
||||
]]></style>
|
||||
</head>
|
||||
<body>
|
||||
<p>If the UA does not display WOFF metadata, the test passes if the word PASS appears below.</p>
|
||||
<p>The Extended Metadata Block is not valid and must not be displayed. If the UA does display it, the test fails.</p>
|
||||
<div class="test">P</div>
|
||||
</body>
|
||||
</html>
|
|
@ -1,37 +0,0 @@
|
|||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||
<head>
|
||||
<meta http-equiv="content-type" content="text/html;charset=UTF-8"/>
|
||||
<title>WOFF Test: No id Attribute in uniqueid Element</title>
|
||||
<link rel="author" title="Tal Leming" href="http://typesupply.com" />
|
||||
<link rel="help" href="http://dev.w3.org/webfonts/WOFF2/spec/#Metadata" />
|
||||
<link rel="help" href="http://www.w3.org/TR/WOFF/#conform-metadata-noeffect" />
|
||||
<link rel="help" href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-metadata-id-required" />
|
||||
<link rel="reviewer" title="Chris Lilley" href="mailto:chris@w3.org" />
|
||||
<link rel="match" href="metadatadisplay-schema-uniqueid-004-ref.xht" />
|
||||
<meta name="assert" content="The uniqueid element does not contain the required id attribute." />
|
||||
<style type="text/css"><![CDATA[
|
||||
@import url("support/test-fonts.css");
|
||||
@font-face {
|
||||
font-family: "WOFF Test";
|
||||
src: url("support/metadatadisplay-schema-uniqueid-004.woff2") format("woff2");
|
||||
}
|
||||
body {
|
||||
font-size: 20px;
|
||||
}
|
||||
pre {
|
||||
font-size: 12px;
|
||||
}
|
||||
.test {
|
||||
font-family: "WOFF Test", "WOFF Test CFF Fallback";
|
||||
font-size: 200px;
|
||||
margin-top: 50px;
|
||||
}
|
||||
]]></style>
|
||||
</head>
|
||||
<body>
|
||||
<p>If the UA does not display WOFF metadata, the test passes if the word PASS appears below.</p>
|
||||
<p>The Extended Metadata Block is not valid and must not be displayed. If the UA does display it, the test fails.</p>
|
||||
<div class="test">P</div>
|
||||
</body>
|
||||
</html>
|
|
@ -1,32 +0,0 @@
|
|||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||
<head>
|
||||
<meta http-equiv="content-type" content="text/html;charset=UTF-8"/>
|
||||
<title>WOFF Test: No name Attribute in vendor Element</title>
|
||||
<link rel="author" title="Tal Leming" href="http://typesupply.com" />
|
||||
<link rel="help" href="http://dev.w3.org/webfonts/WOFF2/spec/#Metadata" />
|
||||
<link rel="help" href="http://www.w3.org/TR/WOFF/#conform-metadata-noeffect" />
|
||||
<link rel="help" href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-metadata-vendor-required" />
|
||||
<link rel="reviewer" title="Chris Lilley" href="mailto:chris@w3.org" />
|
||||
<meta name="assert" content="The vendor element does not contain the required name attribute." />
|
||||
<style type="text/css"><![CDATA[
|
||||
@import url("support/test-fonts.css");
|
||||
body {
|
||||
font-size: 20px;
|
||||
}
|
||||
pre {
|
||||
font-size: 12px;
|
||||
}
|
||||
.test {
|
||||
font-family: "WOFF Test CFF Reference";
|
||||
font-size: 200px;
|
||||
margin-top: 50px;
|
||||
}
|
||||
]]></style>
|
||||
</head>
|
||||
<body>
|
||||
<p>If the UA does not display WOFF metadata, the test passes if the word PASS appears below.</p>
|
||||
<p>The Extended Metadata Block is not valid and must not be displayed. If the UA does display it, the test fails.</p>
|
||||
<div class="test">P</div>
|
||||
</body>
|
||||
</html>
|
|
@ -1,37 +0,0 @@
|
|||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||
<head>
|
||||
<meta http-equiv="content-type" content="text/html;charset=UTF-8"/>
|
||||
<title>WOFF Test: No name Attribute in vendor Element</title>
|
||||
<link rel="author" title="Tal Leming" href="http://typesupply.com" />
|
||||
<link rel="help" href="http://dev.w3.org/webfonts/WOFF2/spec/#Metadata" />
|
||||
<link rel="help" href="http://www.w3.org/TR/WOFF/#conform-metadata-noeffect" />
|
||||
<link rel="help" href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-metadata-vendor-required" />
|
||||
<link rel="reviewer" title="Chris Lilley" href="mailto:chris@w3.org" />
|
||||
<link rel="match" href="metadatadisplay-schema-vendor-005-ref.xht" />
|
||||
<meta name="assert" content="The vendor element does not contain the required name attribute." />
|
||||
<style type="text/css"><![CDATA[
|
||||
@import url("support/test-fonts.css");
|
||||
@font-face {
|
||||
font-family: "WOFF Test";
|
||||
src: url("support/metadatadisplay-schema-vendor-005.woff2") format("woff2");
|
||||
}
|
||||
body {
|
||||
font-size: 20px;
|
||||
}
|
||||
pre {
|
||||
font-size: 12px;
|
||||
}
|
||||
.test {
|
||||
font-family: "WOFF Test", "WOFF Test CFF Fallback";
|
||||
font-size: 200px;
|
||||
margin-top: 50px;
|
||||
}
|
||||
]]></style>
|
||||
</head>
|
||||
<body>
|
||||
<p>If the UA does not display WOFF metadata, the test passes if the word PASS appears below.</p>
|
||||
<p>The Extended Metadata Block is not valid and must not be displayed. If the UA does display it, the test fails.</p>
|
||||
<div class="test">P</div>
|
||||
</body>
|
||||
</html>
|
|
@ -5,9 +5,11 @@
|
|||
<title>WOFF Test: Font access</title>
|
||||
<link rel="author" title="Tal Leming" href="http://typesupply.com" />
|
||||
<link rel="author" title="Chris Lilley" href="http://www.w3.org/People" />
|
||||
<link rel="reviewer" title="Chris Lilley" href="mailto:chris@w3.org" />
|
||||
<link rel="help" href="http://dev.w3.org/webfonts/WOFF2/spec/#General" />
|
||||
<link rel="help" href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-css3font-available" />
|
||||
<meta name="assert" content="Linked fonts are only available to the documents that reference them" />
|
||||
<meta name="flags" content="interact" />
|
||||
<meta name="assert" content="Linked fonts are only available to the documents that reference them." />
|
||||
<style type="text/css"><![CDATA[
|
||||
@import url("test-fonts.css");
|
||||
@font-face {
|
||||
|
|
|
@ -5,9 +5,11 @@
|
|||
<title>WOFF Test: Font access</title>
|
||||
<link rel="author" title="Tal Leming" href="http://typesupply.com" />
|
||||
<link rel="author" title="Chris Lilley" href="http://www.w3.org/People" />
|
||||
<link rel="reviewer" title="Chris Lilley" href="mailto:chris@w3.org" />
|
||||
<link rel="help" href="http://dev.w3.org/webfonts/WOFF2/spec/#General" />
|
||||
<link rel="help" href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-css3font-available" />
|
||||
<meta name="assert" content="Linked fonts are only available to the documents that reference them" />
|
||||
<meta name="flags" content="interact" />
|
||||
<meta name="assert" content="Linked fonts are only available to the documents that reference them." />
|
||||
<style type="text/css"><![CDATA[
|
||||
@import url("test-fonts.css");
|
||||
body {
|
||||
|
|
Binary file not shown.
|
@ -0,0 +1,33 @@
|
|||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||
<head>
|
||||
<meta http-equiv="content-type" content="text/html;charset=UTF-8"/>
|
||||
<title>WOFF Test: Font access</title>
|
||||
<link rel="author" title="Khaled Hosny" href="http://khaledhosny.org" />
|
||||
<link rel="reviewer" title="Chris Lilley" href="mailto:chris@w3.org" />
|
||||
<link rel="help" href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-mustLoadFontCollection" />
|
||||
<meta name="flags" content="interact" />
|
||||
<meta name="assert" content="Fonts must be loaded from font collections." />
|
||||
<style type="text/css"><![CDATA[
|
||||
@import url("test-fonts.css");
|
||||
@font-face {
|
||||
font-family: "WOFF Test";
|
||||
src: url("support/available-002.woff2#1") format("woff2");
|
||||
}
|
||||
body {
|
||||
font-size: 20px;
|
||||
}
|
||||
pre {
|
||||
font-size: 12px;
|
||||
}
|
||||
.test {
|
||||
font-family: "WOFF Test", "WOFF Test CFF Fallback";
|
||||
font-size: 200px;
|
||||
margin-top: 50px;
|
||||
}
|
||||
]]></style>
|
||||
</head>
|
||||
<body>
|
||||
<div class="test">P</div>
|
||||
</body>
|
||||
</html>
|
|
@ -0,0 +1,33 @@
|
|||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||
<head>
|
||||
<meta http-equiv="content-type" content="text/html;charset=UTF-8"/>
|
||||
<title>WOFF Test: Font access</title>
|
||||
<link rel="author" title="Khaled Hosny" href="http://khaledhosny.org" />
|
||||
<link rel="reviewer" title="Chris Lilley" href="mailto:chris@w3.org" />
|
||||
<link rel="help" href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-mustLoadFontCollection" />
|
||||
<meta name="flags" content="font" />
|
||||
<meta name="assert" content="Fonts must be loaded from font collections." />
|
||||
<style type="text/css"><![CDATA[
|
||||
@import url("test-fonts.css");
|
||||
@font-face {
|
||||
font-family: "WOFF Test";
|
||||
src: url("available-002.woff2#2") format("woff2");
|
||||
}
|
||||
body {
|
||||
font-size: 20px;
|
||||
}
|
||||
pre {
|
||||
font-size: 12px;
|
||||
}
|
||||
.test {
|
||||
font-family: "WOFF Test", "WOFF Test CFF Fallback";
|
||||
font-size: 200px;
|
||||
margin-top: 50px;
|
||||
}
|
||||
]]></style>
|
||||
</head>
|
||||
<body>
|
||||
<div class="test">P</div>
|
||||
</body>
|
||||
</html>
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
|
@ -2,12 +2,12 @@
|
|||
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||
<head>
|
||||
<meta http-equiv="content-type" content="text/html;charset=UTF-8"/>
|
||||
<title>WOFF Test: Decompressed Metadata Length Greater Than metaOrigLength</title>
|
||||
<link rel="author" title="Tal Leming" href="http://typesupply.com" />
|
||||
<link rel="help" href="http://dev.w3.org/webfonts/WOFF2/spec/#Metadata" />
|
||||
<link rel="help" href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-metaOrigLength" />
|
||||
<title>WOFF Test: Glyf OrigLength Mismatching</title>
|
||||
<link rel="author" title="Khaled Hosny" href="http://khaledhosny.org" />
|
||||
<link rel="help" href="http://dev.w3.org/webfonts/WOFF2/spec/#DataTables" />
|
||||
<link rel="help" href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-mustNotRejectGlyfSizeMismatch" />
|
||||
<link rel="reviewer" title="Chris Lilley" href="mailto:chris@w3.org" />
|
||||
<meta name="assert" content="The metadata decompresses to a length that is 1 byte greater than the length defined in metaOrigLength" />
|
||||
<meta name="assert" content="The origLength field of glyf table is larger than constructed table." />
|
||||
<style type="text/css"><![CDATA[
|
||||
@import url("support/test-fonts.css");
|
||||
body {
|
||||
|
@ -24,8 +24,7 @@
|
|||
]]></style>
|
||||
</head>
|
||||
<body>
|
||||
<p>If the UA does not display WOFF metadata, the test passes if the word PASS appears below.</p>
|
||||
<p>The Extended Metadata Block is not valid and must not be displayed. If the UA does display it, the test fails.</p>
|
||||
<p>Test passes if the word PASS appears below.</p>
|
||||
<div class="test">P</div>
|
||||
</body>
|
||||
</html>
|
|
@ -2,18 +2,18 @@
|
|||
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||
<head>
|
||||
<meta http-equiv="content-type" content="text/html;charset=UTF-8"/>
|
||||
<title>WOFF Test: Decompressed Metadata Length Greater Than metaOrigLength</title>
|
||||
<link rel="author" title="Tal Leming" href="http://typesupply.com" />
|
||||
<link rel="help" href="http://dev.w3.org/webfonts/WOFF2/spec/#Metadata" />
|
||||
<link rel="help" href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-metaOrigLength" />
|
||||
<title>WOFF Test: Glyf OrigLength Mismatching</title>
|
||||
<link rel="author" title="Khaled Hosny" href="http://khaledhosny.org" />
|
||||
<link rel="help" href="http://dev.w3.org/webfonts/WOFF2/spec/#DataTables" />
|
||||
<link rel="help" href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-mustNotRejectGlyfSizeMismatch" />
|
||||
<link rel="reviewer" title="Chris Lilley" href="mailto:chris@w3.org" />
|
||||
<link rel="match" href="metadatadisplay-metaOrigLength-002-ref.xht" />
|
||||
<meta name="assert" content="The metadata decompresses to a length that is 1 byte greater than the length defined in metaOrigLength" />
|
||||
<link rel="match" href="tabledata-glyf-origlength-003-ref.xht" />
|
||||
<meta name="assert" content="The origLength field of glyf table is larger than constructed table." />
|
||||
<style type="text/css"><![CDATA[
|
||||
@import url("support/test-fonts.css");
|
||||
@font-face {
|
||||
font-family: "WOFF Test";
|
||||
src: url("support/metadatadisplay-metaOrigLength-002.woff2") format("woff2");
|
||||
src: url("support/tabledata-glyf-origlength-003.woff2") format("woff2");
|
||||
}
|
||||
body {
|
||||
font-size: 20px;
|
||||
|
@ -29,8 +29,7 @@
|
|||
]]></style>
|
||||
</head>
|
||||
<body>
|
||||
<p>If the UA does not display WOFF metadata, the test passes if the word PASS appears below.</p>
|
||||
<p>The Extended Metadata Block is not valid and must not be displayed. If the UA does display it, the test fails.</p>
|
||||
<p>Test passes if the word PASS appears below.</p>
|
||||
<div class="test">P</div>
|
||||
</body>
|
||||
</html>
|
|
@ -3,11 +3,11 @@
|
|||
<head>
|
||||
<title>WOFF 2.0: User Agent Test Suite</title>
|
||||
<style type="text/css">
|
||||
@import "resources/index.css";
|
||||
@import "support/index.css";
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<h1>WOFF 2.0: User Agent Test Suite (303 tests)</h1>
|
||||
<h1>WOFF 2.0: User Agent Test Suite (300 tests)</h1>
|
||||
|
||||
<h2 class="testCategory">Valid WOFFs</h2>
|
||||
<div class="testCase" id="valid-001">
|
||||
|
@ -21,7 +21,7 @@
|
|||
<p><a href="valid-001-ref.xht">Reference Rendering</a></p>
|
||||
</div>
|
||||
<div class="testCaseExpectations">
|
||||
<p>SFNT Expectation: Display (<a href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-metadata-noeffect">conform-metadata-noeffect</a> <a href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-private-noeffect">conform-private-noeffect</a>)</p>
|
||||
<p>SFNT Expectation: Display (<a href="http://www.w3.org/TR/WOFF/#conform-metadata-noeffect">conform-metadata-noeffect</a> <a href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-private-noeffect">conform-private-noeffect</a>)</p>
|
||||
<p>Metadata Expectation: None</p>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -37,8 +37,8 @@
|
|||
<p><a href="valid-002-ref.xht">Reference Rendering</a></p>
|
||||
</div>
|
||||
<div class="testCaseExpectations">
|
||||
<p>SFNT Expectation: Display (<a href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-metadata-noeffect">conform-metadata-noeffect</a> <a href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-private-noeffect">conform-private-noeffect</a>)</p>
|
||||
<p>Metadata Expectation: Display <a href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-metadata-maydisplay">(conform-metadata-maydisplay)</a></p>
|
||||
<p>SFNT Expectation: Display (<a href="http://www.w3.org/TR/WOFF/#conform-metadata-noeffect">conform-metadata-noeffect</a> <a href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-private-noeffect">conform-private-noeffect</a>)</p>
|
||||
<p>Metadata Expectation: Display <a href="http://www.w3.org/TR/WOFF/#conform-metadata-maydisplay">(conform-metadata-maydisplay)</a></p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -53,7 +53,7 @@
|
|||
<p><a href="valid-003-ref.xht">Reference Rendering</a></p>
|
||||
</div>
|
||||
<div class="testCaseExpectations">
|
||||
<p>SFNT Expectation: Display (<a href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-metadata-noeffect">conform-metadata-noeffect</a> <a href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-private-noeffect">conform-private-noeffect</a>)</p>
|
||||
<p>SFNT Expectation: Display (<a href="http://www.w3.org/TR/WOFF/#conform-metadata-noeffect">conform-metadata-noeffect</a> <a href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-private-noeffect">conform-private-noeffect</a>)</p>
|
||||
<p>Metadata Expectation: None</p>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -69,8 +69,8 @@
|
|||
<p><a href="valid-004-ref.xht">Reference Rendering</a></p>
|
||||
</div>
|
||||
<div class="testCaseExpectations">
|
||||
<p>SFNT Expectation: Display (<a href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-metadata-noeffect">conform-metadata-noeffect</a> <a href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-private-noeffect">conform-private-noeffect</a>)</p>
|
||||
<p>Metadata Expectation: Display <a href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-metadata-maydisplay">(conform-metadata-maydisplay)</a></p>
|
||||
<p>SFNT Expectation: Display (<a href="http://www.w3.org/TR/WOFF/#conform-metadata-noeffect">conform-metadata-noeffect</a> <a href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-private-noeffect">conform-private-noeffect</a>)</p>
|
||||
<p>Metadata Expectation: Display <a href="http://www.w3.org/TR/WOFF/#conform-metadata-maydisplay">(conform-metadata-maydisplay)</a></p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -85,7 +85,7 @@
|
|||
<p><a href="valid-005-ref.xht">Reference Rendering</a></p>
|
||||
</div>
|
||||
<div class="testCaseExpectations">
|
||||
<p>SFNT Expectation: Display (<a href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-metadata-noeffect">conform-metadata-noeffect</a> <a href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-private-noeffect">conform-private-noeffect</a>)</p>
|
||||
<p>SFNT Expectation: Display (<a href="http://www.w3.org/TR/WOFF/#conform-metadata-noeffect">conform-metadata-noeffect</a> <a href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-private-noeffect">conform-private-noeffect</a>)</p>
|
||||
<p>Metadata Expectation: None</p>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -101,8 +101,8 @@
|
|||
<p><a href="valid-006-ref.xht">Reference Rendering</a></p>
|
||||
</div>
|
||||
<div class="testCaseExpectations">
|
||||
<p>SFNT Expectation: Display (<a href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-metadata-noeffect">conform-metadata-noeffect</a> <a href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-private-noeffect">conform-private-noeffect</a>)</p>
|
||||
<p>Metadata Expectation: Display <a href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-metadata-maydisplay">(conform-metadata-maydisplay)</a></p>
|
||||
<p>SFNT Expectation: Display (<a href="http://www.w3.org/TR/WOFF/#conform-metadata-noeffect">conform-metadata-noeffect</a> <a href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-private-noeffect">conform-private-noeffect</a>)</p>
|
||||
<p>Metadata Expectation: Display <a href="http://www.w3.org/TR/WOFF/#conform-metadata-maydisplay">(conform-metadata-maydisplay)</a></p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -117,7 +117,7 @@
|
|||
<p><a href="valid-007-ref.xht">Reference Rendering</a></p>
|
||||
</div>
|
||||
<div class="testCaseExpectations">
|
||||
<p>SFNT Expectation: Display (<a href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-metadata-noeffect">conform-metadata-noeffect</a> <a href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-private-noeffect">conform-private-noeffect</a>)</p>
|
||||
<p>SFNT Expectation: Display (<a href="http://www.w3.org/TR/WOFF/#conform-metadata-noeffect">conform-metadata-noeffect</a> <a href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-private-noeffect">conform-private-noeffect</a>)</p>
|
||||
<p>Metadata Expectation: None</p>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -133,24 +133,8 @@
|
|||
<p><a href="valid-008-ref.xht">Reference Rendering</a></p>
|
||||
</div>
|
||||
<div class="testCaseExpectations">
|
||||
<p>SFNT Expectation: Display (<a href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-metadata-noeffect">conform-metadata-noeffect</a> <a href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-private-noeffect">conform-private-noeffect</a>)</p>
|
||||
<p>Metadata Expectation: Display <a href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-metadata-maydisplay">(conform-metadata-maydisplay)</a></p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="testCase" id="valid-009">
|
||||
<div class="testCaseOverview">
|
||||
<h3><a href="#valid-009">valid-009</a>: Valid WOFF 9</h3>
|
||||
<p>Valid TTF flavored WOFF with simple and composite glyphs</p>
|
||||
</div>
|
||||
<div class="testCaseDetails">
|
||||
<div class="testCasePages">
|
||||
<p><a href="valid-009.xht">Test</a></p>
|
||||
<p><a href="valid-009-ref.xht">Reference Rendering</a></p>
|
||||
</div>
|
||||
<div class="testCaseExpectations">
|
||||
<p>SFNT Expectation: Display (<a href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-mustProduceOFF">conform-mustProduceOFF</a>)</p>
|
||||
<p>Metadata Expectation: None</p>
|
||||
<p>SFNT Expectation: Display (<a href="http://www.w3.org/TR/WOFF/#conform-metadata-noeffect">conform-metadata-noeffect</a> <a href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-private-noeffect">conform-private-noeffect</a>)</p>
|
||||
<p>Metadata Expectation: Display <a href="http://www.w3.org/TR/WOFF/#conform-metadata-maydisplay">(conform-metadata-maydisplay)</a></p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -514,6 +498,22 @@
|
|||
</div>
|
||||
|
||||
<h2 class="testCategory">WOFF Table Directory Tests</h2>
|
||||
<div class="testCase" id="directory-knowntags-001">
|
||||
<div class="testCaseOverview">
|
||||
<h3><a href="#directory-knowntags-001">directory-knowntags-001</a>: Valid SFNT With Cutsom Tag For Known Table</h3>
|
||||
<p>Valid TTF flavored SFNT font with table directory using custom tag instead of known table flag for some know tables.</p>
|
||||
</div>
|
||||
<div class="testCaseDetails">
|
||||
<div class="testCasePages">
|
||||
<p><a href="directory-knowntags-001.xht">Test</a></p>
|
||||
<p><a href="directory-knowntags-001-ref.xht">Reference Rendering</a></p>
|
||||
</div>
|
||||
<div class="testCaseExpectations">
|
||||
<p>SFNT Expectation: Display (<a href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-mayAcceptKnownTagsAsCustom">conform-mayAcceptKnownTagsAsCustom</a>)</p>
|
||||
<p>Metadata Expectation: None</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="testCase" id="directory-mismatched-tables-001">
|
||||
<div class="testCaseOverview">
|
||||
<h3><a href="#directory-mismatched-tables-001">directory-mismatched-tables-001</a>: Font Collection With Mismatched Glyf/Loca Tables</h3>
|
||||
|
@ -735,7 +735,7 @@
|
|||
<p><a href="tabledata-glyf-bbox-003-ref.xht">Reference Rendering</a></p>
|
||||
</div>
|
||||
<div class="testCaseExpectations">
|
||||
<p>SFNT Expectation: Reject (<a href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-mustRejectNonEmptyBBox">conform-mustRejectNonEmptyBBox</a>)</p>
|
||||
<p>SFNT Expectation: Reject (<a href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-mustRejectNonEmptyBBox2">conform-mustRejectNonEmptyBBox2</a>)</p>
|
||||
<p>Metadata Expectation: None</p>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -806,8 +806,8 @@
|
|||
</div>
|
||||
<div class="testCase" id="tabledata-transform-hmtx-003">
|
||||
<div class="testCaseOverview">
|
||||
<h3><a href="#tabledata-transform-hmtx-003">tabledata-transform-hmtx-003</a>: Transformed Hmtx Table With Bad Flags 1</h3>
|
||||
<p>Invalid TTF flavored WOFF with transformed hmtx table with non-zero reserved bits of the flags field.</p>
|
||||
<h3><a href="#tabledata-transform-hmtx-003">tabledata-transform-hmtx-003</a>: Transformed Hmtx Table With All Flags Set</h3>
|
||||
<p>Invalid TTF flavored WOFF with transformed hmtx table that has all flags bits (including reserved bits) set.</p>
|
||||
</div>
|
||||
<div class="testCaseDetails">
|
||||
<div class="testCasePages">
|
||||
|
@ -822,8 +822,8 @@
|
|||
</div>
|
||||
<div class="testCase" id="tabledata-transform-hmtx-004">
|
||||
<div class="testCaseOverview">
|
||||
<h3><a href="#tabledata-transform-hmtx-004">tabledata-transform-hmtx-004</a>: Transformed Hmtx Table With Bad Flags 2</h3>
|
||||
<p>Invalid TTF flavored WOFF with transformed hmtx table with all flags bits set to 0</p>
|
||||
<h3><a href="#tabledata-transform-hmtx-004">tabledata-transform-hmtx-004</a>: Transformed Hmtx Table With 0 Flags</h3>
|
||||
<p>Invalid TTF flavored WOFF with transformed hmtx table that has 0 flags (null transform).</p>
|
||||
</div>
|
||||
<div class="testCaseDetails">
|
||||
<div class="testCasePages">
|
||||
|
@ -868,6 +868,22 @@
|
|||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="testCase" id="tabledata-glyf-origlength-003">
|
||||
<div class="testCaseOverview">
|
||||
<h3><a href="#tabledata-glyf-origlength-003">tabledata-glyf-origlength-003</a>: Glyf OrigLength Mismatching</h3>
|
||||
<p>The origLength field of glyf table is larger than constructed table.</p>
|
||||
</div>
|
||||
<div class="testCaseDetails">
|
||||
<div class="testCasePages">
|
||||
<p><a href="tabledata-glyf-origlength-003.xht">Test</a></p>
|
||||
<p><a href="tabledata-glyf-origlength-003-ref.xht">Reference Rendering</a></p>
|
||||
</div>
|
||||
<div class="testCaseExpectations">
|
||||
<p>SFNT Expectation: Display (<a href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-mustNotRejectGlyfSizeMismatch">conform-mustNotRejectGlyfSizeMismatch</a>)</p>
|
||||
<p>Metadata Expectation: None</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<h2 class="testCategory">WOFF Metadata Tests</h2>
|
||||
<div class="testCase" id="metadata-noeffect-001">
|
||||
|
@ -881,7 +897,7 @@
|
|||
<p><a href="metadata-noeffect-001-ref.xht">Reference Rendering</a></p>
|
||||
</div>
|
||||
<div class="testCaseExpectations">
|
||||
<p>SFNT Expectation: Display (<a href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-metadata-noeffect">conform-metadata-noeffect</a>)</p>
|
||||
<p>SFNT Expectation: Display (<a href="http://www.w3.org/TR/WOFF/#conform-metadata-noeffect">conform-metadata-noeffect</a>)</p>
|
||||
<p>Metadata Expectation: None</p>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -897,8 +913,8 @@
|
|||
<p><a href="metadata-noeffect-002-ref.xht">Reference Rendering</a></p>
|
||||
</div>
|
||||
<div class="testCaseExpectations">
|
||||
<p>SFNT Expectation: Display (<a href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-metadata-noeffect">conform-metadata-noeffect</a>)</p>
|
||||
<p>Metadata Expectation: Display <a href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-metadata-maydisplay">(conform-metadata-maydisplay)</a></p>
|
||||
<p>SFNT Expectation: Display (<a href="http://www.w3.org/TR/WOFF/#conform-metadata-noeffect">conform-metadata-noeffect</a>)</p>
|
||||
<p>Metadata Expectation: Display <a href="http://www.w3.org/TR/WOFF/#conform-metadata-maydisplay">(conform-metadata-maydisplay)</a></p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -950,55 +966,7 @@
|
|||
</div>
|
||||
<div class="testCaseExpectations">
|
||||
<p>SFNT Expectation: Display (<a href="http://dev.w3.org/webfonts/WOFF2/spec/">documentation</a>)</p>
|
||||
<p>Metadata Expectation: Display <a href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-metadata-authoritative">(conform-metadata-authoritative)</a></p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="testCase" id="metadatadisplay-compression-001">
|
||||
<div class="testCaseOverview">
|
||||
<h3><a href="#metadatadisplay-compression-001">metadatadisplay-compression-001</a>: Metadata No Compression</h3>
|
||||
<p>The metadata is stored in an uncompressed state and therefore does not have the proper compression format.</p>
|
||||
</div>
|
||||
<div class="testCaseDetails">
|
||||
<div class="testCasePages">
|
||||
<p><a href="metadatadisplay-compression-001.xht">Test</a></p>
|
||||
<p><a href="metadatadisplay-compression-001-ref.xht">Reference Rendering</a></p>
|
||||
</div>
|
||||
<div class="testCaseExpectations">
|
||||
<p>SFNT Expectation: Display (<a href="http://dev.w3.org/webfonts/WOFF2/spec/">documentation</a>)</p>
|
||||
<p>Metadata Expectation: Reject <a href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-metadata-alwayscompress">(conform-metadata-alwayscompress)</a></p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="testCase" id="metadatadisplay-metaOrigLength-001">
|
||||
<div class="testCaseOverview">
|
||||
<h3><a href="#metadatadisplay-metaOrigLength-001">metadatadisplay-metaOrigLength-001</a>: Decompressed Metadata Length Less Than metaOrigLength</h3>
|
||||
<p>The metadata decompresses to a length that is 1 byte smaller than the length defined in metaOrigLength</p>
|
||||
</div>
|
||||
<div class="testCaseDetails">
|
||||
<div class="testCasePages">
|
||||
<p><a href="metadatadisplay-metaOrigLength-001.xht">Test</a></p>
|
||||
<p><a href="metadatadisplay-metaOrigLength-001-ref.xht">Reference Rendering</a></p>
|
||||
</div>
|
||||
<div class="testCaseExpectations">
|
||||
<p>SFNT Expectation: Display (<a href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-metaOrigLength">conform-metaOrigLength</a>)</p>
|
||||
<p>Metadata Expectation: Reject</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="testCase" id="metadatadisplay-metaOrigLength-002">
|
||||
<div class="testCaseOverview">
|
||||
<h3><a href="#metadatadisplay-metaOrigLength-002">metadatadisplay-metaOrigLength-002</a>: Decompressed Metadata Length Greater Than metaOrigLength</h3>
|
||||
<p>The metadata decompresses to a length that is 1 byte greater than the length defined in metaOrigLength</p>
|
||||
</div>
|
||||
<div class="testCaseDetails">
|
||||
<div class="testCasePages">
|
||||
<p><a href="metadatadisplay-metaOrigLength-002.xht">Test</a></p>
|
||||
<p><a href="metadatadisplay-metaOrigLength-002-ref.xht">Reference Rendering</a></p>
|
||||
</div>
|
||||
<div class="testCaseExpectations">
|
||||
<p>SFNT Expectation: Display (<a href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-metaOrigLength">conform-metaOrigLength</a>)</p>
|
||||
<p>Metadata Expectation: Reject</p>
|
||||
<p>Metadata Expectation: Display <a href="http://www.w3.org/TR/WOFF/#conform-metadata-authoritative">(conform-metadata-authoritative)</a></p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -1014,7 +982,7 @@
|
|||
</div>
|
||||
<div class="testCaseExpectations">
|
||||
<p>SFNT Expectation: Display (<a href="http://www.w3.org/TR/WOFF/#conform-metadata-noeffect">conform-metadata-noeffect</a>)</p>
|
||||
<p>Metadata Expectation: Reject <a href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-invalid-mustignore">(conform-invalid-mustignore)</a></p>
|
||||
<p>Metadata Expectation: Reject <a href="http://www.w3.org/TR/WOFF/#conform-invalid-mustignore">(conform-invalid-mustignore)</a></p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -1030,7 +998,7 @@
|
|||
</div>
|
||||
<div class="testCaseExpectations">
|
||||
<p>SFNT Expectation: Display (<a href="http://www.w3.org/TR/WOFF/#conform-metadata-noeffect">conform-metadata-noeffect</a>)</p>
|
||||
<p>Metadata Expectation: Reject <a href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-invalid-mustignore">(conform-invalid-mustignore)</a></p>
|
||||
<p>Metadata Expectation: Reject <a href="http://www.w3.org/TR/WOFF/#conform-invalid-mustignore">(conform-invalid-mustignore)</a></p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -1046,7 +1014,7 @@
|
|||
</div>
|
||||
<div class="testCaseExpectations">
|
||||
<p>SFNT Expectation: Display (<a href="http://www.w3.org/TR/WOFF/#conform-metadata-noeffect">conform-metadata-noeffect</a>)</p>
|
||||
<p>Metadata Expectation: Reject <a href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-invalid-mustignore">(conform-invalid-mustignore)</a></p>
|
||||
<p>Metadata Expectation: Reject <a href="http://www.w3.org/TR/WOFF/#conform-invalid-mustignore">(conform-invalid-mustignore)</a></p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -1062,7 +1030,7 @@
|
|||
</div>
|
||||
<div class="testCaseExpectations">
|
||||
<p>SFNT Expectation: Display (<a href="http://www.w3.org/TR/WOFF/#conform-metadata-noeffect">conform-metadata-noeffect</a>)</p>
|
||||
<p>Metadata Expectation: Reject <a href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-invalid-mustignore">(conform-invalid-mustignore)</a></p>
|
||||
<p>Metadata Expectation: Reject <a href="http://www.w3.org/TR/WOFF/#conform-invalid-mustignore">(conform-invalid-mustignore)</a></p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -1078,7 +1046,7 @@
|
|||
</div>
|
||||
<div class="testCaseExpectations">
|
||||
<p>SFNT Expectation: Display (<a href="http://www.w3.org/TR/WOFF/#conform-metadata-noeffect">conform-metadata-noeffect</a>)</p>
|
||||
<p>Metadata Expectation: Reject <a href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-invalid-mustignore">(conform-invalid-mustignore)</a></p>
|
||||
<p>Metadata Expectation: Reject <a href="http://www.w3.org/TR/WOFF/#conform-invalid-mustignore">(conform-invalid-mustignore)</a></p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -1094,7 +1062,7 @@
|
|||
</div>
|
||||
<div class="testCaseExpectations">
|
||||
<p>SFNT Expectation: Display (<a href="http://www.w3.org/TR/WOFF/#conform-metadata-noeffect">conform-metadata-noeffect</a>)</p>
|
||||
<p>Metadata Expectation: Reject <a href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-invalid-mustignore">(conform-invalid-mustignore)</a></p>
|
||||
<p>Metadata Expectation: Reject <a href="http://www.w3.org/TR/WOFF/#conform-invalid-mustignore">(conform-invalid-mustignore)</a></p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -1110,7 +1078,7 @@
|
|||
</div>
|
||||
<div class="testCaseExpectations">
|
||||
<p>SFNT Expectation: Display (<a href="http://www.w3.org/TR/WOFF/#conform-metadata-noeffect">conform-metadata-noeffect</a>)</p>
|
||||
<p>Metadata Expectation: Reject <a href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-invalid-mustignore">(conform-invalid-mustignore)</a></p>
|
||||
<p>Metadata Expectation: Reject <a href="http://www.w3.org/TR/WOFF/#conform-invalid-mustignore">(conform-invalid-mustignore)</a></p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -1158,7 +1126,7 @@
|
|||
</div>
|
||||
<div class="testCaseExpectations">
|
||||
<p>SFNT Expectation: Display (<a href="http://www.w3.org/TR/WOFF/#conform-metadata-noeffect">conform-metadata-noeffect</a>)</p>
|
||||
<p>Metadata Expectation: Reject <a href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-invalid-mustignore">(conform-invalid-mustignore)</a></p>
|
||||
<p>Metadata Expectation: Reject <a href="http://www.w3.org/TR/WOFF/#conform-invalid-mustignore">(conform-invalid-mustignore)</a></p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -1206,7 +1174,7 @@
|
|||
</div>
|
||||
<div class="testCaseExpectations">
|
||||
<p>SFNT Expectation: Display (<a href="http://www.w3.org/TR/WOFF/#conform-metadata-noeffect">conform-metadata-noeffect</a>)</p>
|
||||
<p>Metadata Expectation: Reject <a href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-invalid-mustignore">(conform-invalid-mustignore)</a></p>
|
||||
<p>Metadata Expectation: Reject <a href="http://www.w3.org/TR/WOFF/#conform-invalid-mustignore">(conform-invalid-mustignore)</a></p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -1354,22 +1322,6 @@
|
|||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="testCase" id="metadatadisplay-schema-uniqueid-004">
|
||||
<div class="testCaseOverview">
|
||||
<h3><a href="#metadatadisplay-schema-uniqueid-004">metadatadisplay-schema-uniqueid-004</a>: No id Attribute in uniqueid Element</h3>
|
||||
<p>The uniqueid element does not contain the required id attribute.</p>
|
||||
</div>
|
||||
<div class="testCaseDetails">
|
||||
<div class="testCasePages">
|
||||
<p><a href="metadatadisplay-schema-uniqueid-004.xht">Test</a></p>
|
||||
<p><a href="metadatadisplay-schema-uniqueid-004-ref.xht">Reference Rendering</a></p>
|
||||
</div>
|
||||
<div class="testCaseExpectations">
|
||||
<p>SFNT Expectation: Display (<a href="http://www.w3.org/TR/WOFF/#conform-metadata-noeffect">conform-metadata-noeffect</a>)</p>
|
||||
<p>Metadata Expectation: Reject <a href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-metadata-id-required">(conform-metadata-id-required)</a></p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="testCase" id="metadatadisplay-schema-uniqueid-005">
|
||||
<div class="testCaseOverview">
|
||||
<h3><a href="#metadatadisplay-schema-uniqueid-005">metadatadisplay-schema-uniqueid-005</a>: Unknown Attribute in uniqueid Element</h3>
|
||||
|
@ -1482,22 +1434,6 @@
|
|||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="testCase" id="metadatadisplay-schema-vendor-005">
|
||||
<div class="testCaseOverview">
|
||||
<h3><a href="#metadatadisplay-schema-vendor-005">metadatadisplay-schema-vendor-005</a>: No name Attribute in vendor Element</h3>
|
||||
<p>The vendor element does not contain the required name attribute.</p>
|
||||
</div>
|
||||
<div class="testCaseDetails">
|
||||
<div class="testCasePages">
|
||||
<p><a href="metadatadisplay-schema-vendor-005.xht">Test</a></p>
|
||||
<p><a href="metadatadisplay-schema-vendor-005-ref.xht">Reference Rendering</a></p>
|
||||
</div>
|
||||
<div class="testCaseExpectations">
|
||||
<p>SFNT Expectation: Display (<a href="http://www.w3.org/TR/WOFF/#conform-metadata-noeffect">conform-metadata-noeffect</a>)</p>
|
||||
<p>Metadata Expectation: Reject <a href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-metadata-vendor-required">(conform-metadata-vendor-required)</a></p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="testCase" id="metadatadisplay-schema-vendor-006">
|
||||
<div class="testCaseOverview">
|
||||
<h3><a href="#metadatadisplay-schema-vendor-006">metadatadisplay-schema-vendor-006</a>: Valid dir Attribute in vendor Element 1</h3>
|
||||
|
@ -4863,7 +4799,7 @@
|
|||
<div class="testCase" id="available-001">
|
||||
<div class="testCaseOverview">
|
||||
<h3><a href="#available-001">available-001</a>: Font access</h3>
|
||||
<p>Linked fonts are only available to the documents that reference them</p>
|
||||
<p>Linked fonts are only available to the documents that reference them.</p>
|
||||
</div>
|
||||
<div class="testCaseDetails">
|
||||
<div class="testCasePages">
|
||||
|
@ -4875,5 +4811,20 @@
|
|||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="testCase" id="available-002">
|
||||
<div class="testCaseOverview">
|
||||
<h3><a href="#available-002">available-002</a>: Loading font collections</h3>
|
||||
<p>Fonts must be loaded from font collections.</p>
|
||||
</div>
|
||||
<div class="testCaseDetails">
|
||||
<div class="testCasePages">
|
||||
<p><a href="available-002.xht">Test</a></p>
|
||||
</div>
|
||||
<div class="testCaseExpectations">
|
||||
<p>SFNT Expectation: Display (<a href="http://dev.w3.org/webfonts/WOFF2/spec/#conform-mustLoadFontCollection">conform-mustLoadFontCollection</a>)</p>
|
||||
<p>Metadata Expectation: None</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
|
@ -1,12 +1,12 @@
|
|||
<!doctype html>
|
||||
<html lang=en>
|
||||
<meta charset=utf-8>
|
||||
<title>CSS-contain test: paint containment on non-atomic inlines</title>
|
||||
<title>CSS-contain test: layout containment on non-atomic inlines</title>
|
||||
<link rel="author" title="Florian Rivoal" href="https://florian.rivoal.net">
|
||||
<meta name=flags content="">
|
||||
<meta name=assert content="paint containment does not apply to non atomic inlines">
|
||||
<meta name=assert content="layout containment does not apply to non atomic inlines">
|
||||
<link rel="match" href="reference/contain-size-001-ref.html">
|
||||
<link rel=help href="https://drafts.csswg.org/css-contain-1/#containment-paint">
|
||||
<link rel=help href="https://drafts.csswg.org/css-contain-1/#containment-layout">
|
||||
|
||||
<style>
|
||||
span {
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
<meta name=flags content="ahem">
|
||||
<meta name=assert content="layout containment does not apply to ruby-base">
|
||||
<link rel="match" href="reference/contain-layout-002-ref.html">
|
||||
<link rel=help href="https://drafts.csswg.org/css-contain-1/#containment-paint">
|
||||
<link rel=help href="https://drafts.csswg.org/css-contain-1/#containment-layout">
|
||||
|
||||
<style>
|
||||
rb {
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
<meta name=flags content="ahem">
|
||||
<meta name=assert content="layout containment does not apply to ruby-base-container">
|
||||
<link rel="match" href="reference/contain-layout-002-ref.html">
|
||||
<link rel=help href="https://drafts.csswg.org/css-contain-1/#containment-paint">
|
||||
<link rel=help href="https://drafts.csswg.org/css-contain-1/#containment-layout">
|
||||
|
||||
<style>
|
||||
rbc {
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
<meta name=flags content="ahem">
|
||||
<meta name=assert content="layout containment does not apply to ruby-text-container">
|
||||
<link rel="match" href="reference/contain-layout-004-ref.html">
|
||||
<link rel=help href="https://drafts.csswg.org/css-contain-1/#containment-paint">
|
||||
<link rel=help href="https://drafts.csswg.org/css-contain-1/#containment-layout">
|
||||
|
||||
<style>
|
||||
rtc {
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
<meta name=flags content="ahem">
|
||||
<meta name=assert content="layout containment does not apply to ruby-text">
|
||||
<link rel="match" href="reference/contain-layout-005-ref.html">
|
||||
<link rel=help href="https://drafts.csswg.org/css-contain-1/#containment-paint">
|
||||
<link rel=help href="https://drafts.csswg.org/css-contain-1/#containment-layout">
|
||||
|
||||
<style>
|
||||
rt {
|
||||
|
|
|
@ -0,0 +1,29 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>CSS Containment Test: Layout containment independent formatting context</title>
|
||||
<link rel="author" title="Manuel Rego Casasnovas" href="mailto:rego@igalia.com">
|
||||
<link rel="help" href="https://drafts.csswg.org/css-contain-1/#containment-layout">
|
||||
<link rel="match" href="reference/contain-paint-013-ref.html">
|
||||
<meta name=assert content="Layout containment elements establish an independent formatting context. The test checks that this feature of layout containment applies to blocks and inline blocks, but it doesn't apply to inline elements.">
|
||||
<style>
|
||||
.wrapper {
|
||||
border: solid thick;
|
||||
margin: 1em;
|
||||
}
|
||||
</style>
|
||||
<p>Test passes if on the first two boxes the top and bottom margins of the text line are double size than on the last box.</p>
|
||||
<div class="wrapper">
|
||||
<div style="margin: 1em 0; contain: layout;">
|
||||
<div style="margin: 1em 0;">This text should have 2em top and bottom margins (margins do not collapse).</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="wrapper">
|
||||
<span style="display: inline-block; margin: 1em 0; contain: layout;">
|
||||
<div style="margin: 1em 0;">This text should have 2em top and bottom margins (margins do not collapse).</div>
|
||||
</span>
|
||||
</div>
|
||||
<div class="wrapper">
|
||||
<span style="margin: 1em 0; contain: layout;">
|
||||
<div style="margin: 1em 0;">This text should have 1em top and bottom margins.</div>
|
||||
</span>
|
||||
</div>
|
|
@ -0,0 +1,37 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset=utf-8>
|
||||
<title>CSS Containment Test: Layout containment on table-row-group</title>
|
||||
<link rel="author" title="Manuel Rego Casasnovas" href="mailto:rego@igalia.com">
|
||||
<link rel="help" href="https://drafts.csswg.org/css-contain-1/#containment-layout">
|
||||
<link rel="match" href="../reference/ref-filled-green-100px-square.xht">
|
||||
<meta name=flags content="ahem">
|
||||
<meta name=assert content="Layout containment doesn't apply to table-row-group elements.">
|
||||
|
||||
<style>
|
||||
#wrapper {
|
||||
position: relative;
|
||||
background: red;
|
||||
width: 100px;
|
||||
height: 100px;
|
||||
padding: 25px;
|
||||
box-sizing: border-box;
|
||||
}
|
||||
#table-row-group {
|
||||
display: table-row-group;
|
||||
contain: layout;
|
||||
}
|
||||
#abspos {
|
||||
position: absolute;
|
||||
font: 100px/1 Ahem;
|
||||
color: green;
|
||||
top: 0;
|
||||
left: 0;
|
||||
}
|
||||
</style>
|
||||
|
||||
<p>Test passes if there is a filled green square and <strong>no red</strong>.</p>
|
||||
<div id="wrapper">
|
||||
<div id="table-row-group">
|
||||
<div id="abspos">X</div>
|
||||
</div>
|
||||
</div>
|
|
@ -0,0 +1,37 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset=utf-8>
|
||||
<title>CSS Containment Test: Layout containment on table-header-group</title>
|
||||
<link rel="author" title="Manuel Rego Casasnovas" href="mailto:rego@igalia.com">
|
||||
<link rel="help" href="https://drafts.csswg.org/css-contain-1/#containment-layout">
|
||||
<link rel="match" href="../reference/ref-filled-green-100px-square.xht">
|
||||
<meta name=flags content="ahem">
|
||||
<meta name=assert content="Layout containment doesn't apply to table-header-group elements.">
|
||||
|
||||
<style>
|
||||
#wrapper {
|
||||
position: relative;
|
||||
background: red;
|
||||
width: 100px;
|
||||
height: 100px;
|
||||
padding: 25px;
|
||||
box-sizing: border-box;
|
||||
}
|
||||
#table-header-group {
|
||||
display: table-header-group;
|
||||
contain: layout;
|
||||
}
|
||||
#abspos {
|
||||
position: absolute;
|
||||
font: 100px/1 Ahem;
|
||||
color: green;
|
||||
top: 0;
|
||||
left: 0;
|
||||
}
|
||||
</style>
|
||||
|
||||
<p>Test passes if there is a filled green square and <strong>no red</strong>.</p>
|
||||
<div id="wrapper">
|
||||
<div id="table-header-group">
|
||||
<div id="abspos">X</div>
|
||||
</div>
|
||||
</div>
|
|
@ -0,0 +1,37 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset=utf-8>
|
||||
<title>CSS Containment Test: Layout containment on table-footer-group</title>
|
||||
<link rel="author" title="Manuel Rego Casasnovas" href="mailto:rego@igalia.com">
|
||||
<link rel="help" href="https://drafts.csswg.org/css-contain-1/#containment-layout">
|
||||
<link rel="match" href="../reference/ref-filled-green-100px-square.xht">
|
||||
<meta name=flags content="ahem">
|
||||
<meta name=assert content="Layout containment doesn't apply to table-footer-group elements.">
|
||||
|
||||
<style>
|
||||
#wrapper {
|
||||
position: relative;
|
||||
background: red;
|
||||
width: 100px;
|
||||
height: 100px;
|
||||
padding: 25px;
|
||||
box-sizing: border-box;
|
||||
}
|
||||
#table-footer-group {
|
||||
display: table-footer-group;
|
||||
contain: layout;
|
||||
}
|
||||
#abspos {
|
||||
position: absolute;
|
||||
font: 100px/1 Ahem;
|
||||
color: green;
|
||||
top: 0;
|
||||
left: 0;
|
||||
}
|
||||
</style>
|
||||
|
||||
<p>Test passes if there is a filled green square and <strong>no red</strong>.</p>
|
||||
<div id="wrapper">
|
||||
<div id="table-footer-group">
|
||||
<div id="abspos">X</div>
|
||||
</div>
|
||||
</div>
|
|
@ -0,0 +1,37 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset=utf-8>
|
||||
<title>CSS Containment Test: Layout containment on table-row</title>
|
||||
<link rel="author" title="Manuel Rego Casasnovas" href="mailto:rego@igalia.com">
|
||||
<link rel="help" href="https://drafts.csswg.org/css-contain-1/#containment-layout">
|
||||
<link rel="match" href="../reference/ref-filled-green-100px-square.xht">
|
||||
<meta name=flags content="ahem">
|
||||
<meta name=assert content="Layout containment doesn't apply to table-row elements.">
|
||||
|
||||
<style>
|
||||
#wrapper {
|
||||
position: relative;
|
||||
background: red;
|
||||
width: 100px;
|
||||
height: 100px;
|
||||
padding: 25px;
|
||||
box-sizing: border-box;
|
||||
}
|
||||
#table-row {
|
||||
display: table-row;
|
||||
contain: layout;
|
||||
}
|
||||
#abspos {
|
||||
position: absolute;
|
||||
font: 100px/1 Ahem;
|
||||
color: green;
|
||||
top: 0;
|
||||
left: 0;
|
||||
}
|
||||
</style>
|
||||
|
||||
<p>Test passes if there is a filled green square and <strong>no red</strong>.</p>
|
||||
<div id="wrapper">
|
||||
<div id="table-row">
|
||||
<div id="abspos">X</div>
|
||||
</div>
|
||||
</div>
|
|
@ -0,0 +1,30 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset=utf-8>
|
||||
<title>CSS Containment Test: Layout containment on table-cell</title>
|
||||
<link rel="author" title="Manuel Rego Casasnovas" href="mailto:rego@igalia.com">
|
||||
<link rel="help" href="https://drafts.csswg.org/css-contain-1/#containment-layout">
|
||||
<link rel="match" href="../reference/ref-filled-green-100px-square.xht">
|
||||
<meta name=assert content="Layout containment does apply to table-cell elements.">
|
||||
|
||||
<style>
|
||||
#table-cell {
|
||||
display: table-cell;
|
||||
contain: layout;
|
||||
width: 100px;
|
||||
height: 100px;
|
||||
background: red;
|
||||
}
|
||||
#abspos {
|
||||
position: absolute;
|
||||
bottom: 0;
|
||||
right: 0;
|
||||
background: green;
|
||||
width: 100px;
|
||||
height: 100px;
|
||||
}
|
||||
</style>
|
||||
|
||||
<p>Test passes if there is a filled green square and <strong>no red</strong>.</p>
|
||||
<div id="table-cell">
|
||||
<div id="abspos"></div>
|
||||
</div>
|
|
@ -0,0 +1,30 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset=utf-8>
|
||||
<title>CSS Containment Test: Layout containment on table-caption</title>
|
||||
<link rel="author" title="Manuel Rego Casasnovas" href="mailto:rego@igalia.com">
|
||||
<link rel="help" href="https://drafts.csswg.org/css-contain-1/#containment-layout">
|
||||
<link rel="match" href="../reference/ref-filled-green-100px-square.xht">
|
||||
<meta name=assert content="Layout containment does apply to table-caption elements.">
|
||||
|
||||
<style>
|
||||
#table-caption {
|
||||
display: table-caption;
|
||||
contain: layout;
|
||||
width: 100px;
|
||||
height: 100px;
|
||||
background: red;
|
||||
}
|
||||
#abspos {
|
||||
position: absolute;
|
||||
bottom: 0;
|
||||
right: 0;
|
||||
background: green;
|
||||
width: 100px;
|
||||
height: 100px;
|
||||
}
|
||||
</style>
|
||||
|
||||
<p>Test passes if there is a filled green square and <strong>no red</strong>.</p>
|
||||
<div id="table-caption">
|
||||
<div id="abspos"></div>
|
||||
</div>
|
|
@ -0,0 +1,20 @@
|
|||
<!doctype quirks><!-- Intentional quirks mode -->
|
||||
<title>CSS Test: Flex body in quirks mode</title>
|
||||
<link rel="author" title="Aleks Totic" href="atotic@chromium.org">
|
||||
<link rel="help" href="https://www.w3.org/TR/css-flexbox-1/#main-sizing" title="9.3 Main Size Determination">
|
||||
<link rel="help" href="https://quirks.spec.whatwg.org/#the-body-element-fills-the-html-element-quirk" title="The body element fills the html element quirk">
|
||||
<link rel="match" href="./reference/flexbox_quirks_body-ref.html">
|
||||
<style>
|
||||
html {
|
||||
margin:3px 6px 9px 12px;
|
||||
padding: 0px;
|
||||
background-color: green;
|
||||
}
|
||||
body {
|
||||
display: flex;
|
||||
margin: 7px 11px 14px 23px;
|
||||
padding: 0px;
|
||||
background-color: yellow;
|
||||
}
|
||||
</style>
|
||||
Flex body in quirks mode should fill viewport except for margins.
|
|
@ -0,0 +1,17 @@
|
|||
<!doctype quirks>
|
||||
<title>CSS Test: Flex body in quirks mode</title>
|
||||
<link rel="author" title="Aleks Totic" href="atotic@chromium.org">
|
||||
<style>
|
||||
html {
|
||||
margin:3px 6px 9px 12px;
|
||||
padding: 0px;
|
||||
background-color: green;
|
||||
}
|
||||
body {
|
||||
display: block;
|
||||
margin: 7px 11px 14px 23px;;
|
||||
padding: 0px;
|
||||
background-color: yellow;
|
||||
}
|
||||
</style>
|
||||
Flex body in quirks mode should fill viewport except for margins.
|
|
@ -0,0 +1,15 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8" />
|
||||
<title>CSS Logical Properties: Flow-Relative Border Colors</title>
|
||||
<link rel="author" title="Oriol Brufau" href="mailto:obrufau@igalia.com" />
|
||||
<link rel="help" href="https://drafts.csswg.org/css-logical/#border-color">
|
||||
<meta name="assert" content="This test checks the interaction of the flow-relative border-*-color longhand properties with the physical ones in different writing modes." />
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<div id="log"></div>
|
||||
|
||||
<script src="./resources/test-box-properties.js"></script>
|
||||
<script>
|
||||
runTests(createBoxPropertyGroup("border-*-color", {type: "color"}));
|
||||
</script>
|
|
@ -0,0 +1,15 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8" />
|
||||
<title>CSS Logical Properties: Flow-Relative Border Styles</title>
|
||||
<link rel="author" title="Oriol Brufau" href="mailto:obrufau@igalia.com" />
|
||||
<link rel="help" href="https://drafts.csswg.org/css-logical/#border-style">
|
||||
<meta name="assert" content="This test checks the interaction of the flow-relative border-*-style longhand properties with the physical ones in different writing modes." />
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<div id="log"></div>
|
||||
|
||||
<script src="./resources/test-box-properties.js"></script>
|
||||
<script>
|
||||
runTests(createBoxPropertyGroup("border-*-style", {type: "border-style"}));
|
||||
</script>
|
|
@ -0,0 +1,18 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8" />
|
||||
<title>CSS Logical Properties: Flow-Relative Border Widths</title>
|
||||
<link rel="author" title="Oriol Brufau" href="mailto:obrufau@igalia.com" />
|
||||
<link rel="help" href="https://drafts.csswg.org/css-logical/#border-width">
|
||||
<meta name="assert" content="This test checks the interaction of the flow-relative border-*-width longhand properties with the physical ones in different writing modes." />
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<div id="log"></div>
|
||||
|
||||
<script src="./resources/test-box-properties.js"></script>
|
||||
<script>
|
||||
runTests(createBoxPropertyGroup("border-*-width", {
|
||||
type: "length",
|
||||
prerequisites: {"border-*-style": "solid"},
|
||||
}));
|
||||
</script>
|
|
@ -0,0 +1,18 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8" />
|
||||
<title>CSS Logical Properties: Flow-Relative Offsets</title>
|
||||
<link rel="author" title="Oriol Brufau" href="mailto:obrufau@igalia.com" />
|
||||
<link rel="help" href="https://drafts.csswg.org/css-logical/#inset-properties">
|
||||
<meta name="assert" content="This test checks the interaction of the flow-relative inset-* longhand properties with the physical ones in different writing modes." />
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<div id="log"></div>
|
||||
|
||||
<script src="./resources/test-box-properties.js"></script>
|
||||
<script>
|
||||
runTests(createBoxPropertyGroup("inset-*", {
|
||||
type: "length",
|
||||
prerequisites: {"position": "relative"},
|
||||
}));
|
||||
</script>
|
|
@ -0,0 +1,15 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8" />
|
||||
<title>CSS Logical Properties: Flow-Relative Margins</title>
|
||||
<link rel="author" title="Oriol Brufau" href="mailto:obrufau@igalia.com" />
|
||||
<link rel="help" href="https://drafts.csswg.org/css-logical/#margin-properties">
|
||||
<meta name="assert" content="This test checks the interaction of the flow-relative margin-* longhand properties with the physical ones in different writing modes." />
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<div id="log"></div>
|
||||
|
||||
<script src="./resources/test-box-properties.js"></script>
|
||||
<script>
|
||||
runTests(createBoxPropertyGroup("margin-*", {type: "length"}));
|
||||
</script>
|
|
@ -0,0 +1,15 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8" />
|
||||
<title>CSS Logical Properties: Flow-Relative Padding</title>
|
||||
<link rel="author" title="Oriol Brufau" href="mailto:obrufau@igalia.com" />
|
||||
<link rel="help" href="https://drafts.csswg.org/css-logical/#padding-properties">
|
||||
<meta name="assert" content="This test checks the interaction of the flow-relative padding-* longhand properties with the physical ones in different writing modes." />
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<div id="log"></div>
|
||||
|
||||
<script src="./resources/test-box-properties.js"></script>
|
||||
<script>
|
||||
runTests(createBoxPropertyGroup("padding-*", {type: "length"}));
|
||||
</script>
|
|
@ -0,0 +1,17 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8" />
|
||||
<title>CSS Logical Properties: Flow-Relative Sizing</title>
|
||||
<link rel="author" title="Oriol Brufau" href="mailto:obrufau@igalia.com" />
|
||||
<link rel="help" href="https://drafts.csswg.org/css-logical/#dimension-properties">
|
||||
<meta name="assert" content="This test checks the interaction of the flow-relative sizing properties with the physical ones in different writing modes." />
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<div id="log"></div>
|
||||
|
||||
<script src="./resources/test-box-properties.js"></script>
|
||||
<script>
|
||||
runTests(createSizingPropertyGroup(""));
|
||||
runTests(createSizingPropertyGroup("max-"));
|
||||
runTests(createSizingPropertyGroup("min-"));
|
||||
</script>
|
|
@ -0,0 +1,252 @@
|
|||
"use strict";
|
||||
(function(exports) {
|
||||
const sheet = document.head.appendChild(document.createElement("style"));
|
||||
|
||||
// Specify size for outer <div> to avoid unconstrained-size warnings
|
||||
// when writing-mode of the inner test <div> is vertical-*
|
||||
const wrapper = document.body.appendChild(document.createElement("div"));
|
||||
wrapper.style.cssText = "width:100px; height: 100px;";
|
||||
const testElement = wrapper.appendChild(document.createElement("div"));
|
||||
testElement.id = testElement.className = "test";
|
||||
|
||||
// Values to use while testing
|
||||
const testValues = {
|
||||
"length": ["1px", "2px", "3px", "4px", "5px"],
|
||||
"color": ["rgb(1, 1, 1)", "rgb(2, 2, 2)", "rgb(3, 3, 3)", "rgb(4, 4, 4)", "rgb(5, 5, 5)"],
|
||||
"border-style": ["solid", "dashed", "dotted", "double", "groove"],
|
||||
};
|
||||
|
||||
// Six unique overall writing modes for property-mapping purposes.
|
||||
const writingModes = [
|
||||
{
|
||||
styles: [
|
||||
{"writing-mode": "horizontal-tb", "direction": "ltr"},
|
||||
],
|
||||
blockStart: "top", blockEnd: "bottom", inlineStart: "left", inlineEnd: "right",
|
||||
block: "vertical", inline: "horizontal" },
|
||||
{
|
||||
styles: [
|
||||
{"writing-mode": "horizontal-tb", "direction": "rtl"},
|
||||
],
|
||||
blockStart: "top", blockEnd: "bottom", inlineStart: "right", inlineEnd: "left",
|
||||
block: "vertical", inline: "horizontal" },
|
||||
{
|
||||
styles: [
|
||||
{"writing-mode": "vertical-rl", "direction": "rtl"},
|
||||
{"writing-mode": "sideways-rl", "direction": "rtl"},
|
||||
],
|
||||
blockStart: "right", blockEnd: "left", inlineStart: "bottom", inlineEnd: "top",
|
||||
block: "horizontal", inline: "vertical" },
|
||||
{
|
||||
styles: [
|
||||
{"writing-mode": "vertical-rl", "direction": "ltr"},
|
||||
{"writing-mode": "sideways-rl", "direction": "ltr"},
|
||||
],
|
||||
blockStart: "right", blockEnd: "left", inlineStart: "top", inlineEnd: "bottom",
|
||||
block: "horizontal", inline: "vertical" },
|
||||
{
|
||||
styles: [
|
||||
{"writing-mode": "vertical-lr", "direction": "rtl"},
|
||||
{"writing-mode": "sideways-lr", "direction": "ltr"},
|
||||
],
|
||||
blockStart: "left", blockEnd: "right", inlineStart: "bottom", inlineEnd: "top",
|
||||
block: "horizontal", inline: "vertical" },
|
||||
{
|
||||
styles: [
|
||||
{"writing-mode": "vertical-lr", "direction": "ltr"},
|
||||
{"writing-mode": "sideways-lr", "direction": "rtl"},
|
||||
],
|
||||
blockStart: "left", blockEnd: "right", inlineStart: "top", inlineEnd: "bottom",
|
||||
block: "horizontal", inline: "vertical" },
|
||||
];
|
||||
|
||||
function testCSSValues(testName, style, expectedValues) {
|
||||
for (const [property, value] of expectedValues) {
|
||||
assert_equals(style.getPropertyValue(property), value, `${testName}, ${property}`);
|
||||
}
|
||||
}
|
||||
|
||||
function testComputedValues(testName, rules, expectedValues) {
|
||||
sheet.textContent = rules;
|
||||
const cs = getComputedStyle(testElement);
|
||||
testCSSValues(testName, cs, expectedValues);
|
||||
sheet.textContent = "";
|
||||
}
|
||||
|
||||
function makeDeclaration(object = {}, replacement = "*") {
|
||||
let decl = "";
|
||||
for (const [property, value] of Object.entries(object)) {
|
||||
decl += `${property.replace("*", replacement)}: ${value}; `;
|
||||
}
|
||||
return decl;
|
||||
}
|
||||
|
||||
/**
|
||||
* Creates a group of physical and logical box properties, such as
|
||||
*
|
||||
* { physical: {
|
||||
* left: "margin-left", right: "margin-right",
|
||||
* top: "margin-top", bottom: "margin-bottom",
|
||||
* }, logical: {
|
||||
* inlineStart: "margin-inline-start", inlineEnd: "margin-inline-end",
|
||||
* blockStart: "margin-block-start", blockEnd: "margin-block-end",
|
||||
* }, type: "length", prerequisites: "...", property: "'margin-*'" }
|
||||
*
|
||||
* @param {string} property
|
||||
* A string representing the property names, like "margin-*".
|
||||
* @param {Object} descriptor
|
||||
* @param {string} descriptor.type
|
||||
* Describes the kind of values accepted by the property, like "length".
|
||||
* Must be a key from the `testValues` object.
|
||||
* @param {Object={}} descriptor.prerequisites
|
||||
* Represents property declarations that are needed by `property` to work.
|
||||
* For example, border-width properties require a border style.
|
||||
*/
|
||||
exports.createBoxPropertyGroup = function(property, descriptor) {
|
||||
const logical = {};
|
||||
const physical = {};
|
||||
for (const logicalSide of ["inline-start", "inline-end", "block-start", "block-end"]) {
|
||||
const camelCase = logicalSide.replace(/-(.)/g, (match, $1) => $1.toUpperCase());
|
||||
logical[camelCase] = property.replace("*", logicalSide);
|
||||
}
|
||||
const isInset = property === "inset-*";
|
||||
let prerequisites = "";
|
||||
for (const physicalSide of ["left", "right", "top", "bottom"]) {
|
||||
physical[physicalSide] = isInset ? physicalSide : property.replace("*", physicalSide);
|
||||
prerequisites += makeDeclaration(descriptor.prerequisites, physicalSide);
|
||||
}
|
||||
return {name, logical, physical, type: descriptor.type, prerequisites, property};
|
||||
};
|
||||
|
||||
/**
|
||||
* Creates a group of physical and logical sizing properties.
|
||||
*
|
||||
* @param {string} prefix
|
||||
* One of "", "max-" or "min-".
|
||||
*/
|
||||
exports.createSizingPropertyGroup = function(prefix) {
|
||||
return {
|
||||
logical: {
|
||||
inline: `${prefix}inline-size`,
|
||||
block: `${prefix}block-size`,
|
||||
},
|
||||
physical: {
|
||||
horizontal: `${prefix}width`,
|
||||
vertical: `${prefix}height`,
|
||||
},
|
||||
type: "length",
|
||||
prerequisites: makeDeclaration({display: "block"}),
|
||||
property: (prefix ? prefix.slice(0, -1) + " " : "") + "sizing",
|
||||
};
|
||||
};
|
||||
|
||||
/**
|
||||
* Tests a grup of logical and physical properties in different writing modes.
|
||||
*
|
||||
* @param {Object} group
|
||||
* An object returned by createBoxPropertyGroup or createSizingPropertyGroup.
|
||||
*/
|
||||
exports.runTests = function(group) {
|
||||
const values = testValues[group.type];
|
||||
const logicals = Object.values(group.logical);
|
||||
const physicals = Object.values(group.physical);
|
||||
|
||||
test(function() {
|
||||
const expected = [];
|
||||
for (const [i, logicalProp] of logicals.entries()) {
|
||||
testElement.style.setProperty(logicalProp, values[i]);
|
||||
expected.push([logicalProp, values[i]]);
|
||||
}
|
||||
testCSSValues("logical properties in inline style", testElement.style, expected);
|
||||
testElement.style.cssText = "";
|
||||
}, `Test that logical ${group.property} properties are supported.`);
|
||||
|
||||
for (const writingMode of writingModes) {
|
||||
for (const style of writingMode.styles) {
|
||||
const writingModeDecl = makeDeclaration(style);
|
||||
|
||||
const associated = {};
|
||||
for (const [logicalSide, logicalProp] of Object.entries(group.logical)) {
|
||||
const physicalProp = group.physical[writingMode[logicalSide]];
|
||||
associated[logicalProp] = physicalProp;
|
||||
associated[physicalProp] = logicalProp;
|
||||
}
|
||||
|
||||
// Test that logical properties are converted to their physical
|
||||
// equivalent correctly when all in the group are present on a single
|
||||
// declaration, with no overwriting of previous properties and
|
||||
// no physical properties present. We put the writing mode properties
|
||||
// on a separate declaration to test that the computed values of these
|
||||
// properties are used, rather than those on the same declaration.
|
||||
test(function() {
|
||||
let decl = group.prerequisites;
|
||||
const expected = [];
|
||||
for (const [i, logicalProp] of logicals.entries()) {
|
||||
decl += `${logicalProp}: ${values[i]}; `;
|
||||
expected.push([logicalProp, values[i]]);
|
||||
expected.push([associated[logicalProp], values[i]]);
|
||||
}
|
||||
testComputedValues("logical properties on one declaration, writing " +
|
||||
`mode properties on another, '${writingModeDecl}'`,
|
||||
`.test { ${writingModeDecl} } .test { ${decl} }`,
|
||||
expected);
|
||||
}, `Test that logical ${group.property} properties share computed values `
|
||||
+ `with their physical associates, with '${writingModeDecl}'.`);
|
||||
|
||||
// Test that logical and physical properties are cascaded together,
|
||||
// honoring their relative order on a single declaration
|
||||
// (a) with a single logical property after the physical ones
|
||||
// (b) with a single physical property after the logical ones
|
||||
test(function() {
|
||||
for (const lastIsLogical of [true, false]) {
|
||||
const lasts = lastIsLogical ? logicals : physicals;
|
||||
const others = lastIsLogical ? physicals : logicals;
|
||||
for (const lastProp of lasts) {
|
||||
let decl = writingModeDecl + group.prerequisites;
|
||||
const expected = [];
|
||||
for (const [i, prop] of others.entries()) {
|
||||
decl += `${prop}: ${values[i]}; `;
|
||||
const valueIdx = associated[prop] === lastProp ? others.length : i;
|
||||
expected.push([prop, values[valueIdx]]);
|
||||
expected.push([associated[prop], values[valueIdx]]);
|
||||
}
|
||||
decl += `${lastProp}: ${values[others.length]}; `;
|
||||
testComputedValues(`'${lastProp}' last on single declaration, '${writingModeDecl}'`,
|
||||
`.test { ${decl} }`,
|
||||
expected);
|
||||
}
|
||||
}
|
||||
}, `Test that ${group.property} properties honor order of appearance when both `
|
||||
+ `logical and physical associates are declared, with '${writingModeDecl}'.`);
|
||||
|
||||
// Test that logical and physical properties are cascaded properly when
|
||||
// on different declarations
|
||||
// (a) with a logical property in the high specificity rule
|
||||
// (b) with a physical property in the high specificity rule
|
||||
test(function() {
|
||||
for (const highIsLogical of [true, false]) {
|
||||
let lowDecl = writingModeDecl + group.prerequisites;
|
||||
const high = highIsLogical ? logicals : physicals;
|
||||
const others = highIsLogical ? physicals : logicals;
|
||||
for (const [i, prop] of others.entries()) {
|
||||
lowDecl += `${prop}: ${values[i]}; `;
|
||||
}
|
||||
for (const highProp of high) {
|
||||
const highDecl = `${highProp}: ${values[others.length]}; `;
|
||||
const expected = [];
|
||||
for (const [i, prop] of others.entries()) {
|
||||
const valueIdx = associated[prop] === highProp ? others.length : i;
|
||||
expected.push([prop, values[valueIdx]]);
|
||||
expected.push([associated[prop], values[valueIdx]]);
|
||||
}
|
||||
testComputedValues(`'${highProp}', two declarations, '${writingModeDecl}'`,
|
||||
`#test { ${highDecl} } .test { ${lowDecl} }`,
|
||||
expected);
|
||||
}
|
||||
}
|
||||
}, `Test that ${group.property} properties honor selector specificty when both `
|
||||
+ `logical and physical associates are declared, with '${writingModeDecl}'.`);
|
||||
}
|
||||
}
|
||||
};
|
||||
})(window);
|
|
@ -0,0 +1,26 @@
|
|||
<!doctype html>
|
||||
<title>column-count used value when neither column-count nor column-width are auto</title>
|
||||
<link rel=help href=https://www.w3.org/TR/css-multicol-1/#pseudo-algorithm>
|
||||
<link rel=match href=../reference/ref-filled-green-100px-square.xht>
|
||||
<style>
|
||||
div {
|
||||
position: absolute;
|
||||
}
|
||||
.bg {
|
||||
background: red;
|
||||
width: 100px;
|
||||
height: 100px;
|
||||
}
|
||||
.test {
|
||||
line-height: 50px;
|
||||
width: 100px;
|
||||
background: green;
|
||||
columns: 2 20px;
|
||||
column-gap: 0;
|
||||
orphans: 1;
|
||||
widows: 1;
|
||||
}
|
||||
</style>
|
||||
<p>Test passes if there is a filled green square and <strong>no red</strong>.</p>
|
||||
<div class=bg></div>
|
||||
<div class=test><br><br><br><br></div>
|
|
@ -0,0 +1,13 @@
|
|||
<!DOCTYPE html>
|
||||
<title>Fixed-size float in autosized htr in vrl</title>
|
||||
<link rel="author" title="Morten Stenshorne" href="mstensho@chromium.org">
|
||||
<link rel="help" href="https://www.w3.org/TR/css-sizing-3/#intrinsic" title="4. Intrinsic Size Determination">
|
||||
<link rel="match" href="../reference/ref-filled-green-100px-square.xht">
|
||||
<p>Test passes if there is a filled green square and <strong>no red</strong>.</p>
|
||||
<div style="width:100px; height:100px; background:red;">
|
||||
<div style="writing-mode:vertical-rl; background:green;">
|
||||
<div style="writing-mode:horizontal-tb;">
|
||||
<div style="float:left; width:100px; height:100px;"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
|
@ -376,6 +376,19 @@ test(() => {
|
|||
document.body.appendChild(div);
|
||||
assert_true(div instanceof MyElement, 'Undefined element is upgraded on connecting to a document');
|
||||
}, 'document.createElement with unknown "is" value should create "undefined" state element');
|
||||
|
||||
test(() => {
|
||||
class MyElement extends HTMLElement {
|
||||
constructor() {
|
||||
super();
|
||||
this.foo = true;
|
||||
}
|
||||
}
|
||||
customElements.define("my-element", MyElement);
|
||||
|
||||
const instance = document.createElement('my-element', undefined);
|
||||
assert_true(instance.foo);
|
||||
}, 'document.createElement with undefined options value should be upgraded.');
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
|
|
|
@ -14,7 +14,7 @@
|
|||
<meta name="variant" content="?7001-8000">
|
||||
<meta name="variant" content="?8001-9000">
|
||||
<meta name="variant" content="?9001-10000">
|
||||
<meta name="variant" content="?10001-10000">
|
||||
<meta name="variant" content="?10001-11000">
|
||||
<meta name="variant" content="?11001-12000">
|
||||
<meta name="variant" content="?12001-13000">
|
||||
<meta name="variant" content="?13001-14000">
|
||||
|
|
|
@ -14,7 +14,7 @@
|
|||
<meta name="variant" content="?7001-8000">
|
||||
<meta name="variant" content="?8001-9000">
|
||||
<meta name="variant" content="?9001-10000">
|
||||
<meta name="variant" content="?10001-10000">
|
||||
<meta name="variant" content="?10001-11000">
|
||||
<meta name="variant" content="?11001-last">
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
|
|
@ -24,7 +24,8 @@
|
|||
<meta name="variant" content="?17001-18000">
|
||||
<meta name="variant" content="?18001-19000">
|
||||
<meta name="variant" content="?19001-20000">
|
||||
<meta name="variant" content="?20001-last">
|
||||
<meta name="variant" content="?20001-21000">
|
||||
<meta name="variant" content="?21001-last">
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
<script src="/common/subset-tests.js"></script>
|
||||
|
|
|
@ -24,7 +24,8 @@
|
|||
<meta name="variant" content="?17001-18000">
|
||||
<meta name="variant" content="?18001-19000">
|
||||
<meta name="variant" content="?19001-20000">
|
||||
<meta name="variant" content="?20001-last">
|
||||
<meta name="variant" content="?20001-21000">
|
||||
<meta name="variant" content="?21001-last">
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
<script src="/common/subset-tests.js"></script>
|
||||
|
@ -33,6 +34,9 @@
|
|||
<link rel="author" title="Richard Ishida" href="mailto:ishida@w3.org">
|
||||
<link rel="help" href="https://encoding.spec.whatwg.org/#iso-2022-jp">
|
||||
<meta name="assert" content="The browser produces percent-escaped character references when writing characters to an href value and encoding han characters that are not in the iso-2022-jp encoding.">
|
||||
</head>
|
||||
<body>
|
||||
<div id="log"></div>
|
||||
<script src="../../resources/ranges.js"></script>
|
||||
<script>
|
||||
var errors = true;
|
||||
|
@ -47,8 +51,5 @@ function normalizeStr(str) {
|
|||
}
|
||||
</script>
|
||||
<script src="../../resources/encode-href-common.js"></script>
|
||||
</head>
|
||||
<body>
|
||||
<div id="log"></div>
|
||||
</body>
|
||||
</html>
|
||||
|
|
|
@ -24,7 +24,8 @@
|
|||
<meta name="variant" content="?17001-18000">
|
||||
<meta name="variant" content="?18001-19000">
|
||||
<meta name="variant" content="?19001-20000">
|
||||
<meta name="variant" content="?20001-last">
|
||||
<meta name="variant" content="?20001-21000">
|
||||
<meta name="variant" content="?21001-last">
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
<script src="/common/subset-tests.js"></script>
|
||||
|
|
|
@ -14,7 +14,7 @@
|
|||
<meta name="variant" content="?7001-8000">
|
||||
<meta name="variant" content="?8001-9000">
|
||||
<meta name="variant" content="?9001-10000">
|
||||
<meta name="variant" content="?10001-10000">
|
||||
<meta name="variant" content="?10001-11000">
|
||||
<meta name="variant" content="?11001-12000">
|
||||
<meta name="variant" content="?12001-13000">
|
||||
<meta name="variant" content="?13001-14000">
|
||||
|
|
|
@ -37,7 +37,7 @@
|
|||
</head>
|
||||
<body>
|
||||
<div id="log"></div>
|
||||
<script src="../../ranges.js"></script>
|
||||
<script src="../../resources/ranges.js"></script>
|
||||
<script>
|
||||
var errors = false;
|
||||
var encoder = euckrEncoder;
|
||||
|
@ -47,6 +47,6 @@ function expect(result) {
|
|||
return "%" + result.replace(/ /g, "%");
|
||||
}
|
||||
</script>
|
||||
<script src="../../encode-form-common.js"></script>
|
||||
<script src="../../resources/encode-form-common.js"></script>
|
||||
</body>
|
||||
</html>
|
||||
|
|
|
@ -52,9 +52,6 @@ var separator = ",";
|
|||
function expect(result, codepoint) {
|
||||
return "%26%23" + codepoint + "%3B";
|
||||
}
|
||||
function normalizeStr(str) {
|
||||
return str;
|
||||
}
|
||||
</script>
|
||||
<script src="../../resources/encode-form-common.js"></script>
|
||||
</body>
|
||||
|
|
|
@ -37,7 +37,7 @@
|
|||
</head>
|
||||
<body>
|
||||
<div id="log"></div>
|
||||
<script src="../../ranges.js"></script>
|
||||
<script src="../../resources/ranges.js"></script>
|
||||
<script>
|
||||
var errors = false;
|
||||
var encoder = euckrEncoder;
|
||||
|
@ -47,6 +47,6 @@ function expect(result) {
|
|||
return "%" + result.replace(/ /g, "%");
|
||||
}
|
||||
</script>
|
||||
<script src="../../encode-form-common.js"></script>
|
||||
<script src="../../resources/encode-form-common.js"></script>
|
||||
</body>
|
||||
</html>
|
||||
|
|
|
@ -37,7 +37,7 @@
|
|||
</head>
|
||||
<body>
|
||||
<div id="log"></div>
|
||||
<script src="../../ranges.js"></script>
|
||||
<script src="../../resources/ranges.js"></script>
|
||||
<script>
|
||||
var errors = false;
|
||||
var encoder = euckrEncoder;
|
||||
|
@ -47,6 +47,6 @@ function expect(result) {
|
|||
return "%" + result.replace(/ /g, "%");
|
||||
}
|
||||
</script>
|
||||
<script src="../../encode-form-common.js"></script>
|
||||
<script src="../../resources/encode-form-common.js"></script>
|
||||
</body>
|
||||
</html>
|
||||
|
|
|
@ -37,7 +37,7 @@
|
|||
</head>
|
||||
<body>
|
||||
<div id="log"></div>
|
||||
<script src="../../ranges.js"></script>
|
||||
<script src="../../resources/ranges.js"></script>
|
||||
<script>
|
||||
var errors = false;
|
||||
var encoder = euckrEncoder;
|
||||
|
@ -47,6 +47,6 @@ function expect(result) {
|
|||
return "%" + result.replace(/ /g, "%");
|
||||
}
|
||||
</script>
|
||||
<script src="../../encode-form-common.js"></script>
|
||||
<script src="../../resources/encode-form-common.js"></script>
|
||||
</body>
|
||||
</html>
|
||||
|
|
|
@ -37,7 +37,7 @@
|
|||
</head>
|
||||
<body>
|
||||
<div id="log"></div>
|
||||
<script src="../../ranges.js"></script>
|
||||
<script src="../../resources/ranges.js"></script>
|
||||
<script>
|
||||
var errors = false;
|
||||
var encoder = euckrEncoder;
|
||||
|
@ -47,6 +47,6 @@ function expect(result) {
|
|||
return "%" + result.replace(/ /g, "%");
|
||||
}
|
||||
</script>
|
||||
<script src="../../encode-form-common.js"></script>
|
||||
<script src="../../resources/encode-form-common.js"></script>
|
||||
</body>
|
||||
</html>
|
||||
|
|
|
@ -37,7 +37,7 @@
|
|||
</head>
|
||||
<body>
|
||||
<div id="log"></div>
|
||||
<script src="../../ranges.js"></script>
|
||||
<script src="../../resources/ranges.js"></script>
|
||||
<script>
|
||||
var errors = false;
|
||||
var encoder = euckrEncoder;
|
||||
|
@ -47,6 +47,6 @@ function expect(result) {
|
|||
return "%" + result.replace(/ /g, "%");
|
||||
}
|
||||
</script>
|
||||
<script src="../../encode-form-common.js"></script>
|
||||
<script src="../../resources/encode-form-common.js"></script>
|
||||
</body>
|
||||
</html>
|
||||
|
|
|
@ -27,7 +27,7 @@
|
|||
<meta name="variant" content="?20001-21000">
|
||||
<meta name="variant" content="?21001-22000">
|
||||
<meta name="variant" content="?22001-23000">
|
||||
<meta name="variant" content="?23001-last">
|
||||
<<meta name="variant" content="?23001-last">
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
<script src="/common/subset-tests.js"></script>
|
||||
|
|
|
@ -37,7 +37,7 @@
|
|||
</head>
|
||||
<body>
|
||||
<div id="log"></div>
|
||||
<script src="../../ranges.js"></script>
|
||||
<script src="../../resources/ranges.js"></script>
|
||||
<script>
|
||||
var errors = false;
|
||||
var encoder = euckrEncoder;
|
||||
|
@ -46,6 +46,6 @@ function expect(result, codepoint) {
|
|||
return "%" + result.replace(/ /g, "%");
|
||||
}
|
||||
</script>
|
||||
<script src="../../encode-href-common.js"></script>
|
||||
<script src="../../resources/encode-href-common.js"></script>
|
||||
</body>
|
||||
</html>
|
||||
|
|
|
@ -18,16 +18,7 @@
|
|||
<meta name="variant" content="?11001-12000">
|
||||
<meta name="variant" content="?12001-13000">
|
||||
<meta name="variant" content="?13001-14000">
|
||||
<meta name="variant" content="?14001-15000">
|
||||
<meta name="variant" content="?15001-16000">
|
||||
<meta name="variant" content="?16001-17000">
|
||||
<meta name="variant" content="?17001-18000">
|
||||
<meta name="variant" content="?18001-19000">
|
||||
<meta name="variant" content="?19001-20000">
|
||||
<meta name="variant" content="?20001-21000">
|
||||
<meta name="variant" content="?21001-22000">
|
||||
<meta name="variant" content="?22001-23000">
|
||||
<meta name="variant" content="?23001-last">
|
||||
<meta name="variant" content="?14001-last">
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
<script src="/common/subset-tests.js"></script>
|
||||
|
|
|
@ -14,7 +14,7 @@
|
|||
<meta name="variant" content="?7001-8000">
|
||||
<meta name="variant" content="?8001-9000">
|
||||
<meta name="variant" content="?9001-10000">
|
||||
<meta name="variant" content="?10001-10000">
|
||||
<meta name="variant" content="?10001-11000">
|
||||
<meta name="variant" content="?11001-last">
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
|
|
@ -26,12 +26,12 @@
|
|||
<script src="../../resources/ranges.js"></script>
|
||||
<script>
|
||||
var errors = true;
|
||||
var encoder = eucjpEncoder;
|
||||
var encoder = big5Encoder;
|
||||
var ranges = rangesMisc;
|
||||
function expect(result, codepoint) {
|
||||
return "%26%23" + codepoint + "%3B";
|
||||
}
|
||||
</script>
|
||||
<script src="../../resources/encode-form-common.js"></script>
|
||||
<script src="../../resources/encode-href-common.js"></script>
|
||||
</body>
|
||||
</html>
|
||||
|
|
|
@ -1,9 +1,9 @@
|
|||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<meta name="timeout" content="long">
|
||||
<title>Big5 encoding (href)</title>
|
||||
<meta charset="big5"> <!-- test breaks if the server overrides this -->
|
||||
<title>Big5 encoding (href)</title>
|
||||
<meta name="timeout" content="long">
|
||||
<meta name="variant" content="?1-1000">
|
||||
<meta name="variant" content="?1001-2000">
|
||||
<meta name="variant" content="?2001-3000">
|
||||
|
@ -11,7 +11,14 @@
|
|||
<meta name="variant" content="?4001-5000">
|
||||
<meta name="variant" content="?5001-6000">
|
||||
<meta name="variant" content="?6001-7000">
|
||||
<meta name="variant" content="?7001-last">
|
||||
<meta name="variant" content="?7001-8000">
|
||||
<meta name="variant" content="?8001-9000">
|
||||
<meta name="variant" content="?9001-10000">
|
||||
<meta name="variant" content="?10001-11000">
|
||||
<meta name="variant" content="?11001-12000">
|
||||
<meta name="variant" content="?12001-13000">
|
||||
<meta name="variant" content="?13001-14000">
|
||||
<meta name="variant" content="?14001-last">
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
<script src="/common/subset-tests.js"></script>
|
||||
|
|
|
@ -46,7 +46,8 @@
|
|||
143, // imap2
|
||||
179, // bgp
|
||||
389, // ldap
|
||||
465, // smtp+ssl
|
||||
427, // afp (alternate)
|
||||
465, // smtp (alternate)
|
||||
512, // print / exec
|
||||
513, // login
|
||||
514, // shell
|
||||
|
@ -56,12 +57,13 @@
|
|||
531, // chat
|
||||
532, // netnews
|
||||
540, // uucp
|
||||
548, // afp
|
||||
556, // remotefs
|
||||
563, // nntp+ssl
|
||||
587, // smtp
|
||||
587, // smtp (outgoing)
|
||||
601, // syslog-conn
|
||||
636, // ldap+ssl
|
||||
993, // imap+ssl
|
||||
993, // ldap+ssl
|
||||
995, // pop3+ssl
|
||||
2049, // nfs
|
||||
3659, // apple-sasl
|
||||
|
@ -72,6 +74,7 @@
|
|||
6667, // irc (default)
|
||||
6668, // irc (alternate)
|
||||
6669, // irc (alternate)
|
||||
6697, // irc+tls
|
||||
];
|
||||
|
||||
BLOCKED_PORTS_LIST.map(function(a){
|
||||
|
|
|
@ -1,10 +0,0 @@
|
|||
<script>
|
||||
onload = function() {opener.next()}
|
||||
document.write(Math.random());
|
||||
</script>
|
||||
|
||||
<form method="POST" action="">
|
||||
<input type=hidden name=test value=test>
|
||||
<input type=submit>
|
||||
</form>
|
||||
<button onclick="location.reload()">Reload</button>
|
|
@ -4,7 +4,7 @@
|
|||
<script src="/resources/testharnessreport.js"></script>
|
||||
<div id="log"></div>
|
||||
<script>
|
||||
var win = window.open("reload_post_1-1.html");
|
||||
var win = window.open("resources/reload_post_1-1.py");
|
||||
var t = async_test();
|
||||
var posted = false;
|
||||
var reloaded = false;
|
|
@ -0,0 +1,13 @@
|
|||
def main(request, response):
|
||||
headers = [("Content-Type", "text/html")]
|
||||
return headers, '''
|
||||
<script>
|
||||
onload = function() {opener.next()}
|
||||
document.write(Math.random());
|
||||
</script>
|
||||
<form method="POST" action="">
|
||||
<input type=hidden name=test value=test>
|
||||
<input type=submit>
|
||||
</form>
|
||||
<button onclick="location.reload()">Reload</button>
|
||||
'''
|
|
@ -3,7 +3,8 @@
|
|||
<head>
|
||||
<title>Access to sandbox iframe</title>
|
||||
<link rel="author" title="Kinuko Yasuda" href="mailto:kinuko@chromium.org">
|
||||
<link rel="help" href="http://www.w3.org/html/wg/drafts/html/master/browsers.html#sandboxing">
|
||||
<link rel="help" href="https://html.spec.whatwg.org/multipage/#sandboxed-origin-browsing-context-flag">
|
||||
<link rel="help" href="https://html.spec.whatwg.org/multipage/#integration-with-idl">
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
</head>
|
||||
|
@ -17,9 +18,13 @@
|
|||
called++;
|
||||
}
|
||||
function loaded() {
|
||||
assert_equals(document.getElementById('sandboxedframe').contentWindow.document, undefined);
|
||||
assert_equals(called, 0);
|
||||
t.done();
|
||||
t.step(() => {
|
||||
assert_throws("SecurityError", () => {
|
||||
document.getElementById('sandboxedframe').contentWindow.document;
|
||||
});
|
||||
assert_equals(called, 0);
|
||||
t.done();
|
||||
});
|
||||
}
|
||||
</script>
|
||||
|
||||
|
|
|
@ -23,15 +23,16 @@ const expectedDisplay = {
|
|||
'tbody': 'table-row-group',
|
||||
'tfoot': 'table-footer-group',
|
||||
'tr': 'table-row',
|
||||
'td': 'table-cell',
|
||||
'th': 'table-cell',
|
||||
'td': 'none',
|
||||
'th': 'none',
|
||||
};
|
||||
for (const el of document.querySelectorAll("[hidden]")) {
|
||||
test(function() {
|
||||
const style = getComputedStyle(el);
|
||||
assert_equals(style.display, expectedDisplay[el.localName]);
|
||||
if (el instanceof HTMLTableElement ||
|
||||
el instanceof HTMLTableCaptionElement) {
|
||||
el instanceof HTMLTableCaptionElement ||
|
||||
el instanceof HTMLTableCellElement) {
|
||||
assert_equals(style.visibility, 'visible');
|
||||
} else {
|
||||
assert_equals(style.visibility, 'collapse');
|
||||
|
|
|
@ -1,131 +1,137 @@
|
|||
// GENERATED CONTENT - DO NOT EDIT
|
||||
// Content of this file was automatically extracted from the Payment Request API spec.
|
||||
// See https://w3c.github.io/payment-request/
|
||||
// Content of this file was automatically extracted from the
|
||||
// "Payment Request API" spec.
|
||||
// See: https://w3c.github.io/payment-request/
|
||||
|
||||
[Constructor(sequence<PaymentMethodData> methodData, PaymentDetailsInit details, optional PaymentOptions options),
|
||||
SecureContext, Exposed=Window]
|
||||
SecureContext,
|
||||
Exposed=Window]
|
||||
interface PaymentRequest : EventTarget {
|
||||
Promise<PaymentResponse> show(optional Promise<PaymentDetailsUpdate> detailsPromise);
|
||||
Promise<void> abort();
|
||||
Promise<boolean> canMakePayment();
|
||||
Promise<PaymentResponse> show(optional Promise<PaymentDetailsUpdate> detailsPromise);
|
||||
Promise<void> abort();
|
||||
Promise<boolean> canMakePayment();
|
||||
|
||||
readonly attribute DOMString id;
|
||||
readonly attribute PaymentAddress? shippingAddress;
|
||||
readonly attribute DOMString? shippingOption;
|
||||
readonly attribute PaymentShippingType? shippingType;
|
||||
readonly attribute DOMString id;
|
||||
readonly attribute PaymentAddress? shippingAddress;
|
||||
readonly attribute DOMString? shippingOption;
|
||||
readonly attribute PaymentShippingType? shippingType;
|
||||
|
||||
attribute EventHandler onshippingaddresschange;
|
||||
attribute EventHandler onshippingaddresschange;
|
||||
|
||||
attribute EventHandler onshippingoptionchange;
|
||||
attribute EventHandler onshippingoptionchange;
|
||||
};
|
||||
|
||||
dictionary PaymentMethodData {
|
||||
required DOMString supportedMethods;
|
||||
object data;
|
||||
required DOMString supportedMethods;
|
||||
object data;
|
||||
};
|
||||
|
||||
dictionary PaymentCurrencyAmount {
|
||||
required DOMString currency;
|
||||
required DOMString value;
|
||||
required DOMString currency;
|
||||
required DOMString value;
|
||||
};
|
||||
|
||||
dictionary PaymentDetailsBase {
|
||||
sequence<PaymentItem> displayItems;
|
||||
sequence<PaymentShippingOption> shippingOptions;
|
||||
sequence<PaymentDetailsModifier> modifiers;
|
||||
sequence<PaymentItem> displayItems;
|
||||
sequence<PaymentShippingOption> shippingOptions;
|
||||
sequence<PaymentDetailsModifier> modifiers;
|
||||
};
|
||||
|
||||
dictionary PaymentDetailsInit : PaymentDetailsBase {
|
||||
DOMString id;
|
||||
required PaymentItem total;
|
||||
DOMString id;
|
||||
required PaymentItem total;
|
||||
};
|
||||
|
||||
dictionary PaymentDetailsUpdate : PaymentDetailsBase {
|
||||
DOMString error;
|
||||
PaymentItem total;
|
||||
DOMString error;
|
||||
PaymentItem total;
|
||||
};
|
||||
|
||||
dictionary PaymentDetailsModifier {
|
||||
required DOMString supportedMethods;
|
||||
PaymentItem total;
|
||||
sequence<PaymentItem> additionalDisplayItems;
|
||||
object data;
|
||||
required DOMString supportedMethods;
|
||||
PaymentItem total;
|
||||
sequence<PaymentItem> additionalDisplayItems;
|
||||
object data;
|
||||
};
|
||||
|
||||
enum PaymentShippingType {
|
||||
"shipping",
|
||||
"delivery",
|
||||
"pickup"
|
||||
"shipping",
|
||||
"delivery",
|
||||
"pickup"
|
||||
};
|
||||
|
||||
dictionary PaymentOptions {
|
||||
boolean requestPayerName = false;
|
||||
boolean requestPayerEmail = false;
|
||||
boolean requestPayerPhone = false;
|
||||
boolean requestShipping = false;
|
||||
PaymentShippingType shippingType = "shipping";
|
||||
boolean requestPayerName = false;
|
||||
boolean requestPayerEmail = false;
|
||||
boolean requestPayerPhone = false;
|
||||
boolean requestShipping = false;
|
||||
PaymentShippingType shippingType = "shipping";
|
||||
};
|
||||
|
||||
dictionary PaymentItem {
|
||||
required DOMString label;
|
||||
required PaymentCurrencyAmount amount;
|
||||
boolean pending = false;
|
||||
// Note: type member is "at risk" of being removed!
|
||||
PaymentItemType type;
|
||||
required DOMString label;
|
||||
required PaymentCurrencyAmount amount;
|
||||
boolean pending = false;
|
||||
// Note: type member is "at risk" of being removed!
|
||||
PaymentItemType type;
|
||||
};
|
||||
|
||||
enum PaymentItemType {
|
||||
"tax"
|
||||
"tax"
|
||||
};
|
||||
|
||||
[SecureContext, Exposed=Window]
|
||||
[SecureContext,
|
||||
Exposed=(Window)]
|
||||
interface PaymentAddress {
|
||||
[Default] object toJSON();
|
||||
readonly attribute DOMString country;
|
||||
readonly attribute FrozenArray<DOMString> addressLine;
|
||||
readonly attribute DOMString region;
|
||||
readonly attribute DOMString city;
|
||||
readonly attribute DOMString dependentLocality;
|
||||
readonly attribute DOMString postalCode;
|
||||
readonly attribute DOMString sortingCode;
|
||||
readonly attribute DOMString languageCode;
|
||||
readonly attribute DOMString organization;
|
||||
readonly attribute DOMString recipient;
|
||||
readonly attribute DOMString phone;
|
||||
[Default] object toJSON();
|
||||
readonly attribute DOMString city;
|
||||
readonly attribute DOMString country;
|
||||
readonly attribute DOMString dependentLocality;
|
||||
readonly attribute DOMString languageCode;
|
||||
readonly attribute DOMString organization;
|
||||
readonly attribute DOMString phone;
|
||||
readonly attribute DOMString postalCode;
|
||||
readonly attribute DOMString recipient;
|
||||
readonly attribute DOMString region;
|
||||
readonly attribute DOMString regionCode;
|
||||
readonly attribute DOMString sortingCode;
|
||||
readonly attribute FrozenArray<DOMString> addressLine;
|
||||
};
|
||||
dictionary AddressInit {
|
||||
DOMString country;
|
||||
sequence<DOMString> addressLine;
|
||||
DOMString region;
|
||||
DOMString regionCode;
|
||||
DOMString city;
|
||||
DOMString dependentLocality;
|
||||
DOMString postalCode;
|
||||
DOMString sortingCode;
|
||||
DOMString languageCode;
|
||||
DOMString organization;
|
||||
DOMString recipient;
|
||||
DOMString phone;
|
||||
};
|
||||
|
||||
dictionary PaymentShippingOption {
|
||||
required DOMString id;
|
||||
required DOMString label;
|
||||
required PaymentCurrencyAmount amount;
|
||||
boolean selected = false;
|
||||
required DOMString id;
|
||||
required DOMString label;
|
||||
required PaymentCurrencyAmount amount;
|
||||
boolean selected = false;
|
||||
};
|
||||
|
||||
enum PaymentComplete {
|
||||
"fail",
|
||||
"success",
|
||||
"unknown"
|
||||
"fail",
|
||||
"success",
|
||||
"unknown"
|
||||
};
|
||||
|
||||
[SecureContext, Exposed=Window]
|
||||
[SecureContext,
|
||||
Exposed=Window]
|
||||
interface PaymentResponse {
|
||||
[Default] object toJSON();
|
||||
[Default] object toJSON();
|
||||
|
||||
readonly attribute DOMString requestId;
|
||||
readonly attribute DOMString methodName;
|
||||
readonly attribute object details;
|
||||
readonly attribute PaymentAddress? shippingAddress;
|
||||
readonly attribute DOMString? shippingOption;
|
||||
readonly attribute DOMString? payerName;
|
||||
readonly attribute DOMString? payerEmail;
|
||||
readonly attribute DOMString? payerPhone;
|
||||
readonly attribute DOMString requestId;
|
||||
readonly attribute DOMString methodName;
|
||||
readonly attribute object details;
|
||||
readonly attribute PaymentAddress? shippingAddress;
|
||||
readonly attribute DOMString? shippingOption;
|
||||
readonly attribute DOMString? payerName;
|
||||
readonly attribute DOMString? payerEmail;
|
||||
readonly attribute DOMString? payerPhone;
|
||||
|
||||
Promise<void> complete(optional PaymentComplete result = "unknown");
|
||||
Promise<void> complete(optional PaymentComplete result = "unknown");
|
||||
};
|
||||
|
||||
[Constructor(DOMString type, optional PaymentRequestUpdateEventInit eventInitDict), SecureContext, Exposed=Window]
|
||||
[Constructor(DOMString type, optional PaymentRequestUpdateEventInit eventInitDict),
|
||||
SecureContext,
|
||||
Exposed=Window]
|
||||
interface PaymentRequestUpdateEvent : Event {
|
||||
void updateWith(Promise<PaymentDetailsUpdate> detailsPromise);
|
||||
void updateWith(Promise<PaymentDetailsUpdate> detailsPromise);
|
||||
};
|
||||
|
||||
dictionary PaymentRequestUpdateEventInit : EventInit {};
|
||||
dictionary PaymentRequestUpdateEventInit : EventInit {
|
||||
};
|
|
@ -0,0 +1,5 @@
|
|||
test(() => {
|
||||
assert_throws(new TypeError(), () => {
|
||||
new Request("", {importance: 'invalid'});
|
||||
}, "a new Request() must throw a TypeError if RequestInit's importance is an invalid value");
|
||||
}, "new Request() throws a TypeError if any of RequestInit's members' values are invalid");
|
|
@ -20,7 +20,7 @@ from tools.wpt import markdown
|
|||
from tools import localpaths
|
||||
|
||||
logger = None
|
||||
stability_run, write_inconsistent, write_results = None, None, None
|
||||
run_step, write_inconsistent, write_results = None, None, None
|
||||
wptrunner = None
|
||||
|
||||
def setup_logging():
|
||||
|
@ -35,10 +35,9 @@ def setup_logging():
|
|||
|
||||
|
||||
def do_delayed_imports():
|
||||
global stability_run, write_inconsistent, write_results, wptrunner
|
||||
from tools.wpt.stability import run as stability_run
|
||||
from tools.wpt.stability import write_inconsistent, write_results
|
||||
global wptrunner, run_step, write_inconsistent, write_results
|
||||
from wptrunner import wptrunner
|
||||
from wptrunner.stability import run_step, write_inconsistent, write_results
|
||||
|
||||
|
||||
class TravisFold(object):
|
||||
|
@ -266,11 +265,15 @@ def run(venv, wpt_args, **kwargs):
|
|||
|
||||
do_delayed_imports()
|
||||
|
||||
wpt_kwargs["stability"] = True
|
||||
wpt_kwargs["prompt"] = False
|
||||
wpt_kwargs["install_browser"] = True
|
||||
wpt_kwargs["install"] = wpt_kwargs["product"].split(":")[0] == "firefox"
|
||||
|
||||
wpt_kwargs["pause_after_test"] = False
|
||||
wpt_kwargs["verify_log_full"] = True
|
||||
if wpt_kwargs["repeat"] == 1:
|
||||
wpt_kwargs["repeat"] = 10
|
||||
|
||||
wpt_kwargs = setup_wptrunner(venv, **wpt_kwargs)
|
||||
|
||||
logger.info("Using binary %s" % wpt_kwargs["binary"])
|
||||
|
@ -279,9 +282,8 @@ def run(venv, wpt_args, **kwargs):
|
|||
with TravisFold("running_tests"):
|
||||
logger.info("Starting tests")
|
||||
|
||||
|
||||
wpt_logger = wptrunner.logger
|
||||
iterations, results, inconsistent = stability_run(venv, wpt_logger, **wpt_kwargs)
|
||||
results, inconsistent, iterations = run_step(wpt_logger, wpt_kwargs["repeat"], True, {}, **wpt_kwargs)
|
||||
|
||||
if results:
|
||||
if inconsistent:
|
||||
|
|
|
@ -49,8 +49,6 @@ def create_parser():
|
|||
help="Browser to run tests in")
|
||||
parser.add_argument("--yes", "-y", dest="prompt", action="store_false", default=True,
|
||||
help="Don't prompt before installing components")
|
||||
parser.add_argument("--stability", action="store_true",
|
||||
help="Stability check tests")
|
||||
parser.add_argument("--install-browser", action="store_true",
|
||||
help="Install the latest development version of the browser")
|
||||
parser._add_container_actions(wptcommandline.create_parser())
|
||||
|
@ -434,7 +432,6 @@ def setup_wptrunner(venv, prompt=True, install=False, **kwargs):
|
|||
def run(venv, **kwargs):
|
||||
#Remove arguments that aren't passed to wptrunner
|
||||
prompt = kwargs.pop("prompt", True)
|
||||
stability = kwargs.pop("stability", True)
|
||||
install_browser = kwargs.pop("install_browser", False)
|
||||
|
||||
kwargs = setup_wptrunner(venv,
|
||||
|
@ -442,20 +439,7 @@ def run(venv, **kwargs):
|
|||
install=install_browser,
|
||||
**kwargs)
|
||||
|
||||
if stability:
|
||||
import stability
|
||||
iterations, results, inconsistent = stability.run(venv, logger, **kwargs)
|
||||
|
||||
def log(x):
|
||||
print(x)
|
||||
|
||||
if inconsistent:
|
||||
stability.write_inconsistent(log, inconsistent, iterations)
|
||||
else:
|
||||
log("All tests stable")
|
||||
rv = len(inconsistent) > 0
|
||||
else:
|
||||
rv = run_single(venv, **kwargs) > 0
|
||||
rv = run_single(venv, **kwargs) > 0
|
||||
|
||||
return rv
|
||||
|
||||
|
|
|
@ -1,195 +0,0 @@
|
|||
import os
|
||||
import sys
|
||||
from collections import OrderedDict, defaultdict
|
||||
|
||||
from mozlog import reader
|
||||
from mozlog.formatters import JSONFormatter, TbplFormatter
|
||||
from mozlog.handlers import BaseHandler, LogLevelFilter, StreamHandler
|
||||
|
||||
from markdown import markdown_adjust, table
|
||||
from wptrunner import wptrunner
|
||||
|
||||
|
||||
class LogActionFilter(BaseHandler):
|
||||
|
||||
"""Handler that filters out messages not of a given set of actions.
|
||||
|
||||
Subclasses BaseHandler.
|
||||
|
||||
:param inner: Handler to use for messages that pass this filter
|
||||
:param actions: List of actions for which to fire the handler
|
||||
"""
|
||||
|
||||
def __init__(self, inner, actions):
|
||||
"""Extend BaseHandler and set inner and actions props on self."""
|
||||
BaseHandler.__init__(self, inner)
|
||||
self.inner = inner
|
||||
self.actions = actions
|
||||
|
||||
def __call__(self, item):
|
||||
"""Invoke handler if action is in list passed as constructor param."""
|
||||
if item["action"] in self.actions:
|
||||
return self.inner(item)
|
||||
|
||||
|
||||
class LogHandler(reader.LogHandler):
|
||||
|
||||
"""Handle updating test and subtest status in log.
|
||||
|
||||
Subclasses reader.LogHandler.
|
||||
"""
|
||||
def __init__(self):
|
||||
self.results = OrderedDict()
|
||||
|
||||
def find_or_create_test(self, data):
|
||||
test_name = data["test"]
|
||||
if self.results.get(test_name):
|
||||
return self.results[test_name]
|
||||
|
||||
test = {
|
||||
"subtests": OrderedDict(),
|
||||
"status": defaultdict(int)
|
||||
}
|
||||
self.results[test_name] = test
|
||||
return test
|
||||
|
||||
def find_or_create_subtest(self, data):
|
||||
test = self.find_or_create_test(data)
|
||||
subtest_name = data["subtest"]
|
||||
|
||||
if test["subtests"].get(subtest_name):
|
||||
return test["subtests"][subtest_name]
|
||||
|
||||
subtest = {
|
||||
"status": defaultdict(int),
|
||||
"messages": set()
|
||||
}
|
||||
test["subtests"][subtest_name] = subtest
|
||||
|
||||
return subtest
|
||||
|
||||
def test_status(self, data):
|
||||
subtest = self.find_or_create_subtest(data)
|
||||
subtest["status"][data["status"]] += 1
|
||||
if data.get("message"):
|
||||
subtest["messages"].add(data["message"])
|
||||
|
||||
def test_end(self, data):
|
||||
test = self.find_or_create_test(data)
|
||||
test["status"][data["status"]] += 1
|
||||
|
||||
|
||||
def is_inconsistent(results_dict, iterations):
|
||||
"""Return whether or not a single test is inconsistent."""
|
||||
return len(results_dict) > 1 or sum(results_dict.values()) != iterations
|
||||
|
||||
|
||||
def process_results(log, iterations):
|
||||
"""Process test log and return overall results and list of inconsistent tests."""
|
||||
inconsistent = []
|
||||
handler = LogHandler()
|
||||
reader.handle_log(reader.read(log), handler)
|
||||
results = handler.results
|
||||
for test_name, test in results.iteritems():
|
||||
if is_inconsistent(test["status"], iterations):
|
||||
inconsistent.append((test_name, None, test["status"], []))
|
||||
for subtest_name, subtest in test["subtests"].iteritems():
|
||||
if is_inconsistent(subtest["status"], iterations):
|
||||
inconsistent.append((test_name, subtest_name, subtest["status"], subtest["messages"]))
|
||||
return results, inconsistent
|
||||
|
||||
|
||||
def err_string(results_dict, iterations):
|
||||
"""Create and return string with errors from test run."""
|
||||
rv = []
|
||||
total_results = sum(results_dict.values())
|
||||
for key, value in sorted(results_dict.items()):
|
||||
rv.append("%s%s" %
|
||||
(key, ": %s/%s" % (value, iterations) if value != iterations else ""))
|
||||
if total_results < iterations:
|
||||
rv.append("MISSING: %s/%s" % (iterations - total_results, iterations))
|
||||
rv = ", ".join(rv)
|
||||
if is_inconsistent(results_dict, iterations):
|
||||
rv = "**%s**" % rv
|
||||
return rv
|
||||
|
||||
|
||||
def write_inconsistent(log, inconsistent, iterations):
|
||||
"""Output inconsistent tests to logger.error."""
|
||||
log("## Unstable results ##\n")
|
||||
strings = [(
|
||||
"`%s`" % markdown_adjust(test),
|
||||
("`%s`" % markdown_adjust(subtest)) if subtest else "",
|
||||
err_string(results, iterations),
|
||||
("`%s`" % markdown_adjust(";".join(messages))) if len(messages) else "")
|
||||
for test, subtest, results, messages in inconsistent]
|
||||
table(["Test", "Subtest", "Results", "Messages"], strings, log)
|
||||
|
||||
|
||||
def write_results(log, results, iterations, pr_number=None, use_details=False):
|
||||
log("## All results ##\n")
|
||||
if use_details:
|
||||
log("<details>\n")
|
||||
log("<summary>%i %s ran</summary>\n\n" % (len(results),
|
||||
"tests" if len(results) > 1
|
||||
else "test"))
|
||||
|
||||
for test_name, test in results.iteritems():
|
||||
baseurl = "http://w3c-test.org/submissions"
|
||||
if "https" in os.path.splitext(test_name)[0].split(".")[1:]:
|
||||
baseurl = "https://w3c-test.org/submissions"
|
||||
title = test_name
|
||||
if use_details:
|
||||
log("<details>\n")
|
||||
if pr_number:
|
||||
title = "<a href=\"%s/%s%s\">%s</a>" % (baseurl, pr_number, test_name, title)
|
||||
log('<summary>%s</summary>\n\n' % title)
|
||||
else:
|
||||
log("### %s ###" % title)
|
||||
strings = [("", err_string(test["status"], iterations), "")]
|
||||
|
||||
strings.extend(((
|
||||
("`%s`" % markdown_adjust(subtest_name)) if subtest else "",
|
||||
err_string(subtest["status"], iterations),
|
||||
("`%s`" % markdown_adjust(';'.join(subtest["messages"]))) if len(subtest["messages"]) else "")
|
||||
for subtest_name, subtest in test["subtests"].items()))
|
||||
table(["Subtest", "Results", "Messages"], strings, log)
|
||||
if use_details:
|
||||
log("</details>\n")
|
||||
|
||||
if use_details:
|
||||
log("</details>\n")
|
||||
|
||||
|
||||
def run(venv, logger, **kwargs):
|
||||
kwargs["pause_after_test"] = False
|
||||
if kwargs["repeat"] == 1:
|
||||
kwargs["repeat"] = 10
|
||||
|
||||
handler = LogActionFilter(
|
||||
LogLevelFilter(
|
||||
StreamHandler(
|
||||
sys.stdout,
|
||||
TbplFormatter()
|
||||
),
|
||||
"WARNING"),
|
||||
["log", "process_output"])
|
||||
|
||||
# There is a public API for this in the next mozlog
|
||||
initial_handlers = logger._state.handlers
|
||||
logger._state.handlers = []
|
||||
|
||||
with open("raw.log", "wb") as log:
|
||||
# Setup logging for wptrunner that keeps process output and
|
||||
# warning+ level logs only
|
||||
logger.add_handler(handler)
|
||||
logger.add_handler(StreamHandler(log, JSONFormatter()))
|
||||
|
||||
wptrunner.run_tests(**kwargs)
|
||||
|
||||
logger._state.handlers = initial_handlers
|
||||
|
||||
with open("raw.log", "rb") as log:
|
||||
results, inconsistent = process_results(log, kwargs["repeat"])
|
||||
|
||||
return kwargs["repeat"], results, inconsistent
|
|
@ -19,6 +19,9 @@ from ..executors.executorselenium import (SeleniumTestharnessExecutor,
|
|||
SeleniumRefTestExecutor)
|
||||
|
||||
here = os.path.split(__file__)[0]
|
||||
# Number of seconds to wait between polling operations when detecting status of
|
||||
# Sauce Connect sub-process.
|
||||
sc_poll_period = 1
|
||||
|
||||
|
||||
__wptrunner__ = {"product": "sauce",
|
||||
|
@ -170,31 +173,24 @@ class SauceConnect():
|
|||
])
|
||||
|
||||
# Timeout config vars
|
||||
each_sleep_secs = 1
|
||||
max_wait = 30
|
||||
kill_wait = 5
|
||||
|
||||
tot_wait = 0
|
||||
while not os.path.exists('./sauce_is_ready') and self.sc_process.poll() is None:
|
||||
if tot_wait >= max_wait:
|
||||
self.sc_process.terminate()
|
||||
while self.sc_process.poll() is None:
|
||||
time.sleep(each_sleep_secs)
|
||||
tot_wait += each_sleep_secs
|
||||
if tot_wait >= (max_wait + kill_wait):
|
||||
self.sc_process.kill()
|
||||
break
|
||||
self.quit()
|
||||
|
||||
raise SauceException("Sauce Connect Proxy was not ready after %d seconds" % tot_wait)
|
||||
|
||||
time.sleep(each_sleep_secs)
|
||||
tot_wait += each_sleep_secs
|
||||
time.sleep(sc_poll_period)
|
||||
tot_wait += sc_poll_period
|
||||
|
||||
if self.sc_process.returncode is not None:
|
||||
raise SauceException("Unable to start Sauce Connect Proxy. Process exited with code %s", self.sc_process.returncode)
|
||||
|
||||
def __exit__(self, exc_type, exc_val, exc_tb):
|
||||
self.env_config = None
|
||||
self.sc_process.terminate()
|
||||
self.quit()
|
||||
if self.temp_dir and os.path.exists(self.temp_dir):
|
||||
try:
|
||||
shutil.rmtree(self.temp_dir)
|
||||
|
@ -208,6 +204,23 @@ class SauceConnect():
|
|||
with open(os.path.join(here, 'sauce_setup', file_name), 'rb') as f:
|
||||
requests.post(url, data=f, auth=auth)
|
||||
|
||||
def quit(self):
|
||||
"""The Sauce Connect process may be managing an active "tunnel" to the
|
||||
Sauce Labs service. Issue a request to the process to close any tunnels
|
||||
and exit. If this does not occur within 5 seconds, force the process to
|
||||
close."""
|
||||
kill_wait = 5
|
||||
tot_wait = 0
|
||||
self.sc_process.terminate()
|
||||
|
||||
while self.sc_process.poll() is None:
|
||||
time.sleep(sc_poll_period)
|
||||
tot_wait += sc_poll_period
|
||||
|
||||
if tot_wait >= kill_wait:
|
||||
self.sc_process.kill()
|
||||
break
|
||||
|
||||
|
||||
class SauceException(Exception):
|
||||
pass
|
||||
|
|
|
@ -181,8 +181,8 @@ def run_step(logger, iterations, restart_after_iteration, kwargs_extras, **kwarg
|
|||
kwargs.update(kwargs_extras)
|
||||
|
||||
def wrap_handler(x):
|
||||
x = LogLevelFilter(x, "WARNING")
|
||||
if not kwargs["verify_log_full"]:
|
||||
x = LogLevelFilter(x, "WARNING")
|
||||
x = LogActionFilter(x, ["log", "process_output"])
|
||||
return x
|
||||
|
||||
|
|
|
@ -65,6 +65,32 @@ def test_sauceconnect_failure_exit(readyfile, returncode):
|
|||
# Given we appear to exit immediately with these mocks, sleep shouldn't be called
|
||||
sleep.assert_not_called()
|
||||
|
||||
def test_sauceconnect_cleanup():
|
||||
"""Ensure that execution pauses when the process is closed while exiting
|
||||
the context manager. This allow Sauce Connect to close any active
|
||||
tunnels."""
|
||||
with mock.patch.object(sauce.SauceConnect, "upload_prerun_exec"),\
|
||||
mock.patch.object(sauce.subprocess, "Popen") as Popen,\
|
||||
mock.patch.object(sauce.os.path, "exists") as exists,\
|
||||
mock.patch.object(sauce.time, "sleep") as sleep:
|
||||
Popen.return_value.poll.return_value = True
|
||||
Popen.return_value.returncode = None
|
||||
exists.return_value = True
|
||||
|
||||
sauce_connect = sauce.SauceConnect(
|
||||
sauce_user="aaa",
|
||||
sauce_key="bbb",
|
||||
sauce_tunnel_id="ccc",
|
||||
sauce_connect_binary="ddd")
|
||||
|
||||
env_config = Config(browser_host="example.net")
|
||||
sauce_connect(None, env_config)
|
||||
with sauce_connect:
|
||||
Popen.return_value.poll.return_value = None
|
||||
sleep.assert_not_called()
|
||||
|
||||
sleep.assert_called()
|
||||
|
||||
|
||||
def test_sauceconnect_failure_never_ready():
|
||||
with mock.patch.object(sauce.SauceConnect, "upload_prerun_exec"),\
|
||||
|
|
|
@ -1,4 +1,9 @@
|
|||
from tools.wpt import stability
|
||||
import sys
|
||||
from os.path import dirname, join
|
||||
|
||||
sys.path.insert(0, join(dirname(__file__), "..", ".."))
|
||||
|
||||
from wptrunner import stability
|
||||
|
||||
def test_is_inconsistent():
|
||||
assert stability.is_inconsistent({"PASS": 10}, 10) is False
|
Some files were not shown because too many files have changed in this diff Show more
Loading…
Add table
Add a link
Reference in a new issue