diff --git a/components/script/dom/create.rs b/components/script/dom/create.rs index f2b8182cdc3..14e061c07a0 100644 --- a/components/script/dom/create.rs +++ b/components/script/dom/create.rs @@ -175,6 +175,8 @@ pub fn create_element(name: QualName, prefix: Option, atom!("legend") => make!(HTMLLegendElement), atom!("li") => make!(HTMLLIElement), atom!("link") => make!(HTMLLinkElement), + // https://html.spec.whatwg.org/multipage/#other-elements,-attributes-and-apis:listing + atom!("listing") => make!(HTMLPreElement), atom!("main") => make!(HTMLElement), atom!("map") => make!(HTMLMapElement), atom!("mark") => make!(HTMLElement), @@ -241,4 +243,3 @@ pub fn create_element(name: QualName, prefix: Option, _ => make!(HTMLUnknownElement), } } - diff --git a/tests/wpt/metadata/html/dom/interfaces.html.ini b/tests/wpt/metadata/html/dom/interfaces.html.ini index 9a528a172da..4152904127e 100644 --- a/tests/wpt/metadata/html/dom/interfaces.html.ini +++ b/tests/wpt/metadata/html/dom/interfaces.html.ini @@ -2370,12 +2370,6 @@ [HTMLPreElement interface: document.createElement("pre") must inherit property "width" with the proper type (0)] expected: FAIL - [HTMLPreElement must be primary interface of document.createElement("listing")] - expected: FAIL - - [Stringification of document.createElement("listing")] - expected: FAIL - [HTMLPreElement interface: document.createElement("listing") must inherit property "width" with the proper type (0)] expected: FAIL