mirror of
https://github.com/servo/servo.git
synced 2025-08-06 14:10:11 +01:00
Update web-platform-tests to revision ecf36e0069be779649c30b647f6b13f2842c14da
This commit is contained in:
parent
5b79711ece
commit
d97dd12540
29 changed files with 583 additions and 316 deletions
|
@ -24,10 +24,11 @@ link_support_table['a'] = {
|
|||
'apple-touch-icon-precomposed', 'canonical']
|
||||
};
|
||||
link_support_table['area'] = link_support_table['a'];
|
||||
link_support_table['form'] = link_support_table['form'];
|
||||
link_support_table['form'] = link_support_table['a'];
|
||||
|
||||
function test_rellist(tag_name, rel_table) {
|
||||
let element = document.createElement(tag_name);
|
||||
function test_rellist(tag_name) {
|
||||
const rel_table = link_support_table[tag_name];
|
||||
const element = document.createElement(tag_name);
|
||||
let tag = element.tagName;
|
||||
// Test that setting rel is also setting relList, for both
|
||||
// valid and invalid values.
|
||||
|
@ -74,10 +75,10 @@ function test_rellist(tag_name, rel_table) {
|
|||
}
|
||||
}
|
||||
|
||||
test(function() {
|
||||
test_rellist('LINK', link_support_table['link']);
|
||||
test_rellist('A', link_support_table['a']);
|
||||
test_rellist('AREA', link_support_table['area']);
|
||||
test_rellist('FORM', link_support_table['form']);
|
||||
}, 'Make sure that relList based feature detection is working');
|
||||
['link', 'a', 'area', 'form'].forEach(tag_name => {
|
||||
test(
|
||||
() => test_rellist(tag_name),
|
||||
`Make sure that relList based feature detection is working for <${tag_name}>`
|
||||
);
|
||||
});
|
||||
</script>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue