| Index: LayoutTests/fast/dom/custom/registration-context-isolation.html
|
| diff --git a/LayoutTests/fast/dom/custom/registration-context-isolation.html b/LayoutTests/fast/dom/custom/registration-context-isolation.html
|
| index 302a53f3516c7c70d18aaea422ad26754d71d25a..d82bb8fcb275a1cb27f1e5418c42907567708410 100644
|
| --- a/LayoutTests/fast/dom/custom/registration-context-isolation.html
|
| +++ b/LayoutTests/fast/dom/custom/registration-context-isolation.html
|
| @@ -148,4 +148,41 @@ withFrame(t.step_func(function (frame) {
|
|
|
| })();
|
|
|
| +(function () {
|
| +
|
| +var t = async_test('registration context should not be created by ' +
|
| + 'DOMImplementation-created documents');
|
| +
|
| +withFrame(t.step_func(function (frame) {
|
| + // Test transitively sloughing off a registration context through
|
| + // multiple createDocument/createHTMLDocument steps.
|
| +
|
| + var documentA = frame.contentDocument;
|
| +
|
| + // This document is not HTML, XHTML; it will not process custom elements.
|
| + var documentB = documentA.implementation.createDocument(null, '');
|
| + assert_throws(
|
| + 'NOT_SUPPORTED_ERR',
|
| + function() { documentB.registerElement('x-a'); });
|
| +
|
| + // This document will not process custom elements because there is
|
| + // nothing to inherit from B.
|
| + var documentC = documentB.implementation.createHTMLDocument();
|
| + assert_throws(
|
| + 'NOT_SUPPORTED_ERR',
|
| + function() { documentC.registerElement('x-b'); });
|
| +
|
| + // Nor this one.
|
| + var documentD = documentC.implementation.createDocument(
|
| + 'http://www.w3.org/1999/xhtml', 'html');
|
| + assert_throws(
|
| + 'NOT_SUPPORTED_ERR',
|
| + function() { documentD.registerElement('x-c'); });
|
| +
|
| + frame.remove();
|
| + t.done();
|
| +}));
|
| +
|
| +})();
|
| +
|
| </script>
|
|
|