PutForwards cleanup

This commit is contained in:
Patrick Shaughnessy 2020-01-06 22:37:35 -05:00
parent 2b77a992db
commit 8a4df2ae2a
11 changed files with 23 additions and 82 deletions

View file

@ -6,5 +6,5 @@
[Exposed=Window] [Exposed=Window]
interface mixin ElementCSSInlineStyle { interface mixin ElementCSSInlineStyle {
[SameObject/*, PutForwards=cssText*/] readonly attribute CSSStyleDeclaration style; [SameObject, PutForwards=cssText] readonly attribute CSSStyleDeclaration style;
}; };

View file

@ -23,7 +23,7 @@ interface HTMLAnchorElement : HTMLElement {
// attribute USVString ping; // attribute USVString ping;
[CEReactions] [CEReactions]
attribute DOMString rel; attribute DOMString rel;
readonly attribute DOMTokenList relList; [SameObject, PutForwards=value] readonly attribute DOMTokenList relList;
// [CEReactions] // [CEReactions]
// attribute DOMString hreflang; // attribute DOMString hreflang;
// [CEReactions] // [CEReactions]

View file

@ -21,7 +21,7 @@ interface HTMLAreaElement : HTMLElement {
// attribute USVString ping; // attribute USVString ping;
// [CEReactions] // [CEReactions]
// attribute DOMString rel; // attribute DOMString rel;
readonly attribute DOMTokenList relList; [SameObject, PutForwards=value] readonly attribute DOMTokenList relList;
// hreflang and type are not reflected // hreflang and type are not reflected
}; };
//HTMLAreaElement includes HTMLHyperlinkElementUtils; //HTMLAreaElement includes HTMLHyperlinkElementUtils;

View file

@ -13,7 +13,7 @@ interface HTMLLinkElement : HTMLElement {
attribute DOMString? crossOrigin; attribute DOMString? crossOrigin;
[CEReactions] [CEReactions]
attribute DOMString rel; attribute DOMString rel;
readonly attribute DOMTokenList relList; [SameObject, PutForwards=value] readonly attribute DOMTokenList relList;
[CEReactions] [CEReactions]
attribute DOMString media; attribute DOMString media;
[CEReactions] [CEReactions]

View file

@ -473142,7 +473142,7 @@
"testharness" "testharness"
], ],
"WebIDL/ecmascript-binding/put-forwards.html": [ "WebIDL/ecmascript-binding/put-forwards.html": [
"d7cc389b1c88ec6f8c166115dbf45b4bc58b540b", "83ec534b2b358d47cdc4498155dbbca565fc3883",
"testharness" "testharness"
], ],
"WebIDL/ecmascript-binding/sequence-conversion.html": [ "WebIDL/ecmascript-binding/sequence-conversion.html": [

View file

@ -1,20 +1,4 @@
[put-forwards.html] [put-forwards.html]
type: testharness type: testharness
[Overriding getter of [PutForwards\] attribute] [Setting form.relList to noreferrer is reflected in rel]
expected: FAIL expected: FAIL
[Overriding setter of [PutForwards\] target attribute]
expected: FAIL
[Overriding target of [PutForwards\] attribute]
expected: FAIL
[Exception propagation from getter of [PutForwards\] attribute]
expected: FAIL
[Exception propagation from setter of [PutForwards\] target attribute]
expected: FAIL
[TypeError when getter of [PutForwards\] attribute returns non-object]
expected: FAIL

View file

@ -1,49 +1,3 @@
[font-style-parsing.html] [font-style-parsing.html]
[Font-style (computed): 'oblique' followed by calc is valid even if it must be clamped (with computation)]
expected: FAIL
[Font-style (computed): 'oblique' followed by calc is valid even if it must be clamped (no computation)]
expected: FAIL
[Font-style (computed): 'oblique' followed by minimum -90 degree angle is valid]
expected: FAIL
[Font-style (computed): 'italic' is valid]
expected: FAIL
[Font-style (computed): 'oblique' followed by positive angle in turns is valid]
expected: FAIL
[Font-style (computed): 'oblique' followed by fractional angle is valid]
expected: FAIL
[Font-style (computed): 'oblique' followed by positive angle in degrees is valid]
expected: FAIL
[Font-style (computed): 'oblique' followed by positive angle in gradians is valid]
expected: FAIL
[Font-style (computed): 'oblique' followed by positive angle in radians is valid]
expected: FAIL
[Font-style (computed): 'oblique' followed by zero degrees is valid]
expected: FAIL
[Font-style (computed): 'oblique' followed by calc is valid]
expected: FAIL
[Font-style (computed): 'oblique' followed by calc is valid even if it mixes units (with computation)] [Font-style (computed): 'oblique' followed by calc is valid even if it mixes units (with computation)]
expected: FAIL expected: FAIL
[Font-style (computed): 'oblique' followed by positive angle is valid]
expected: FAIL
[Font-style (computed): 'oblique' is valid]
expected: FAIL
[Font-style (computed): 'oblique' followed by maxumum 90 degree angle is valid]
expected: FAIL
[Font-style (computed): 'oblique' followed by negative angle is valid]
expected: FAIL

View file

@ -467,9 +467,6 @@
[CSSRule interface: sheet.cssRules[2\].cssRules[0\] must inherit property "parentStyleSheet" with the proper type] [CSSRule interface: sheet.cssRules[2\].cssRules[0\] must inherit property "parentStyleSheet" with the proper type]
expected: FAIL expected: FAIL
[HTMLElement interface: attribute style]
expected: FAIL
[CSSStyleDeclaration interface: attribute parentRule] [CSSStyleDeclaration interface: attribute parentRule]
expected: FAIL expected: FAIL

View file

@ -3,6 +3,4 @@
[When qualifiedName does not match the QName production, an INVALID_CHARACTER_ERR exception is to be thrown.] [When qualifiedName does not match the QName production, an INVALID_CHARACTER_ERR exception is to be thrown.]
expected: FAIL expected: FAIL
[Toggling element with inline style should make inline style disappear]
expected: FAIL

View file

@ -1932,9 +1932,6 @@
[HTMLInputElement interface: createInput("tel") must inherit property "willValidate" with the proper type] [HTMLInputElement interface: createInput("tel") must inherit property "willValidate" with the proper type]
expected: FAIL expected: FAIL
[HTMLAreaElement interface: attribute relList]
expected: FAIL
[HTMLPreElement interface: document.createElement("listing") must inherit property "width" with the proper type] [HTMLPreElement interface: document.createElement("listing") must inherit property "width" with the proper type]
expected: FAIL expected: FAIL
@ -2526,9 +2523,6 @@
[HTMLMeterElement interface: attribute low] [HTMLMeterElement interface: attribute low]
expected: FAIL expected: FAIL
[HTMLLinkElement interface: attribute relList]
expected: FAIL
[HTMLEmbedElement interface: attribute height] [HTMLEmbedElement interface: attribute height]
expected: FAIL expected: FAIL
@ -3915,9 +3909,6 @@
[HTMLInputElement interface: createInput("radio") must inherit property "useMap" with the proper type] [HTMLInputElement interface: createInput("radio") must inherit property "useMap" with the proper type]
expected: FAIL expected: FAIL
[HTMLAnchorElement interface: attribute relList]
expected: FAIL
[HTMLInputElement interface: createInput("month") must inherit property "setCustomValidity(DOMString)" with the proper type] [HTMLInputElement interface: createInput("month") must inherit property "setCustomValidity(DOMString)" with the proper type]
expected: FAIL expected: FAIL

View file

@ -115,6 +115,7 @@ test(() => {
}); });
}, "TypeError when getter of [PutForwards] attribute returns non-object"); }, "TypeError when getter of [PutForwards] attribute returns non-object");
test(() => { test(() => {
var element = document.createElement("div"); var element = document.createElement("div");
@ -128,4 +129,20 @@ test(() => {
assert_equals(element.style, element_style); assert_equals(element.style, element_style);
assert_equals(element.style.cssText, null); assert_equals(element.style.cssText, null);
}, "Does not throw when setter of [PutForwards] attribute returns false"); }, "Does not throw when setter of [PutForwards] attribute returns false");
function test_token_list(elementName, attribute, target, value) {
test(() => {
var element=document.createElement(elementName);
assert_true(element[attribute] instanceof DOMTokenList,"The attribute is a DOMTokenList");
element[attribute]=value;
assert_equals(element.getAttribute(target),value,"Setting the attribute is reflected in the target");
element[attribute]="";
assert_equals(element.getAttribute(target),"","Clearing the attribute is reflected in the target");
},"Setting "+elementName+"."+attribute+" to "+value+" is reflected in "+target)
}
test_token_list("a","relList","rel","noreferrer");
test_token_list("area","relList","rel","noreferrer");
test_token_list("form","relList","rel","noreferrer");
test_token_list("link","relList","rel","stylesheet");
</script> </script>