Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(262)

Unified Diff: LayoutTests/fast/dom/custom/type-extension-is-null.html

Issue 476713002: Make |extends| option in custom element behave correctly (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Nit Created 6 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « LayoutTests/TestExpectations ('k') | LayoutTests/fast/dom/custom/type-extension-is-null-expected.txt » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: LayoutTests/fast/dom/custom/type-extension-is-null.html
diff --git a/LayoutTests/fast/dom/custom/type-extension-is-null.html b/LayoutTests/fast/dom/custom/type-extension-is-null.html
new file mode 100644
index 0000000000000000000000000000000000000000..263b608e95d341424b80231c4b6f20d63d317ca2
--- /dev/null
+++ b/LayoutTests/fast/dom/custom/type-extension-is-null.html
@@ -0,0 +1,15 @@
+<!DOCTYPE html>
+<script src="../../../resources/testharness.js"></script>
+<script src="../../../resources/testharnessreport.js"></script>
+<body>
+<script>
+test(function() {
+ var A = document.registerElement('x-foo', {extends: null, prototype: null});
+ assert_equals(new A().outerHTML, '<x-foo></x-foo>',
+ 'localName should not be "null" and type extension should not have "is" attribute');
+
+ assert_equals(new A().localName, 'x-foo',
+ 'localName should be set to TYPE if extends is null');
+
+}, 'type extension from null should be treated as if "extends" is not given');
+</script>
« no previous file with comments | « LayoutTests/TestExpectations ('k') | LayoutTests/fast/dom/custom/type-extension-is-null-expected.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698