Move parseFontFaceDescriptor to CSSPropertyParser.cpp
[chromium-blink-merge.git] / third_party / WebKit / LayoutTests / fast / dom / custom / document-register-svg-extends.html
blob51492d3eb49c978d6f0577a7e2505103a9950df8
1 <!DOCTYPE html>
2 <script src="../../../resources/testharness.js"></script>
3 <script src="../../../resources/testharnessreport.js"></script>
4 <body>
5 <script>
6 test(function () {
7 var proto = Object.create(SVGGElement.prototype);
9 assert_throws('NOT_SUPPORTED_ERR', function() {
10 document.registerElement('x-foo', {prototype: proto});
11 }, 'register of an SVG element requires the extends parameter');
13 var XFoo = document.registerElement('x-foo', {prototype: proto, extends: 'g'});
15 var created = new XFoo();
16 assert_true(created instanceof SVGGElement, 'created element should be an SVG element');
18 }, 'registration of SVG types');
19 </script>