New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Implement custom element registry #17112
Merged
+520
−87
Merged
Changes from 1 commit
Commits
Show all changes
3 commits
Select commit
Hold shift + click to select a range
File filter...
Filter file types
Jump to…
Jump to file
Failed to load files.
Loading status checks…
Update test expectations
- Loading branch information
commit 87bf4ca2ef71ccc5ef29a025b4137825cd00369b
| @@ -1,50 +1,8 @@ | ||
| [CustomElementRegistry.html] | ||
| type: testharness | ||
| [CustomElementRegistry interface must have define as a method] | ||
| expected: FAIL | ||
|
|
||
| [customElements.define must throw when the element interface is not a constructor] | ||
| expected: FAIL | ||
|
|
||
| [customElements.define must not throw the constructor is HTMLElement] | ||
| expected: FAIL | ||
|
|
||
| [customElements.define must throw with an invalid name] | ||
| expected: FAIL | ||
|
|
||
| [customElements.define must throw when there is already a custom element of the same name] | ||
| expected: FAIL | ||
|
|
||
| [customElements.define must throw a NotSupportedError when there is already a custom element with the same class] | ||
| expected: FAIL | ||
|
|
||
| [customElements.define must throw a NotSupportedError when element definition is running flag is set] | ||
| expected: FAIL | ||
|
|
||
| [customElements.define must check IsConstructor on the constructor before checking the element definition is running flag] | ||
| expected: FAIL | ||
|
|
||
| [customElements.define must validate the custom element name before checking the element definition is running flag] | ||
| expected: FAIL | ||
|
|
||
| [customElements.define unset the element definition is running flag before upgrading custom elements] | ||
| expected: FAIL | ||
|
|
||
| [customElements.define must not throw when defining another custom element in a different global object during Get(constructor, "prototype")] | ||
cbrewster
Author
Member
|
||
| expected: FAIL | ||
|
|
||
| [Custom Elements: CustomElementRegistry interface] | ||
| expected: FAIL | ||
|
|
||
| [customElements.define must get "prototype" property of the constructor] | ||
| expected: FAIL | ||
|
|
||
| [customElements.define must rethrow an exception thrown while getting "prototype" property of the constructor] | ||
| expected: FAIL | ||
|
|
||
| [customElements.define must throw when "prototype" property of the constructor is not an object] | ||
| expected: FAIL | ||
|
|
||
| [customElements.define must get callbacks of the constructor prototype] | ||
| expected: FAIL | ||
|
|
||
| @@ -69,45 +27,9 @@ | ||
| [customElements.define must rethrow an exception thrown while retrieving Symbol.iterator on observedAttributes] | ||
| expected: FAIL | ||
|
|
||
| [customElements.define must not throw even if "observedAttributes" fails to convert if "attributeChangedCallback" is not defined] | ||
| expected: FAIL | ||
|
|
||
| [customElements.define must define an instantiatable custom element] | ||
| expected: FAIL | ||
|
|
||
| [customElements.define must upgrade elements in the shadow-including tree order] | ||
| expected: FAIL | ||
|
|
||
| [CustomElementRegistry interface must have get as a method] | ||
| expected: FAIL | ||
|
|
||
| [customElements.get must return undefined when the registry does not contain an entry with the given name] | ||
| expected: FAIL | ||
|
|
||
| [customElements.get must return undefined when the registry does not contain an entry with the given name even if the name was not a valid custom element name] | ||
| expected: FAIL | ||
|
|
||
| [customElements.get return the constructor of the entry with the given name when there is a matching entry.] | ||
| expected: FAIL | ||
|
|
||
| [customElements.whenDefined must return a promise for a valid custom element name] | ||
| expected: FAIL | ||
|
|
||
| [customElements.whenDefined must return the same promise each time invoked for a valid custom element name which has not been defined] | ||
| expected: FAIL | ||
|
|
||
| [customElements.whenDefined must return an unresolved promise when the registry does not contain the entry with the given name] | ||
| expected: FAIL | ||
|
|
||
| [customElements.whenDefined must return a rejected promise when the given name is not a valid custom element name] | ||
| expected: FAIL | ||
|
|
||
| [customElements.whenDefined must return a resolved promise when the registry contains the entry with the given name] | ||
| expected: FAIL | ||
|
|
||
| [customElements.whenDefined must return a new resolved promise each time invoked when the registry contains the entry with the given name] | ||
| expected: FAIL | ||
|
|
||
| [A promise returned by customElements.whenDefined must be resolved by "define"] | ||
| expected: FAIL | ||
|
|
||
| @@ -1,5 +1,53 @@ | ||
| [define.html] | ||
| type: testharness | ||
| [Custom Elements: Element definition] | ||
| [If constructor is arrow function, should throw a TypeError] | ||
cbrewster
Author
Member
|
||
| expected: FAIL | ||
|
|
||
| [If constructor.prototype.connectedCallback throws, should rethrow] | ||
| expected: FAIL | ||
|
|
||
| [If constructor.prototype.connectedCallback is null, should throw a TypeError] | ||
| expected: FAIL | ||
|
|
||
| [If constructor.prototype.connectedCallback is object, should throw a TypeError] | ||
| expected: FAIL | ||
|
|
||
| [If constructor.prototype.connectedCallback is integer, should throw a TypeError] | ||
| expected: FAIL | ||
|
|
||
| [If constructor.prototype.disconnectedCallback throws, should rethrow] | ||
| expected: FAIL | ||
|
|
||
| [If constructor.prototype.disconnectedCallback is null, should throw a TypeError] | ||
| expected: FAIL | ||
|
|
||
| [If constructor.prototype.disconnectedCallback is object, should throw a TypeError] | ||
| expected: FAIL | ||
|
|
||
| [If constructor.prototype.disconnectedCallback is integer, should throw a TypeError] | ||
| expected: FAIL | ||
|
|
||
| [If constructor.prototype.adoptedCallback throws, should rethrow] | ||
| expected: FAIL | ||
|
|
||
| [If constructor.prototype.adoptedCallback is null, should throw a TypeError] | ||
| expected: FAIL | ||
|
|
||
| [If constructor.prototype.adoptedCallback is object, should throw a TypeError] | ||
| expected: FAIL | ||
|
|
||
| [If constructor.prototype.adoptedCallback is integer, should throw a TypeError] | ||
| expected: FAIL | ||
|
|
||
| [If constructor.prototype.attributeChangedCallback throws, should rethrow] | ||
| expected: FAIL | ||
|
|
||
| [If constructor.prototype.attributeChangedCallback is null, should throw a TypeError] | ||
| expected: FAIL | ||
|
|
||
| [If constructor.prototype.attributeChangedCallback is object, should throw a TypeError] | ||
| expected: FAIL | ||
|
|
||
| [If constructor.prototype.attributeChangedCallback is integer, should throw a TypeError] | ||
| expected: FAIL | ||
|
|
||
| @@ -1,6 +1,5 @@ | ||
| [parser-constructs-custom-elements.html] | ||
| type: testharness | ||
| expected: ERROR | ||
| [HTML parser must create a defined custom element before executing inline scripts] | ||
| expected: FAIL | ||
|
|
ProTip!
Use n and p to navigate between commits in a pull request.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Can we look into why this test fails?