Browse Source

Make sure test for namespaced elements fail without change

Sebastian Helzle 6 years ago
parent
commit
81705519f9

+ 0 - 9
packages/ckeditor5-engine/tests/view/domconverter/dom-to-view.js

@@ -175,15 +175,6 @@ describe( 'DomConverter', () => {
 			expect( converter.domToView( comment ) ).to.be.null;
 		} );
 
-		it( 'should create namespaced elements', () => {
-			const namespace = 'http://www.w3.org/2000/svg';
-			const svg = createElement( document, 'svg', { xmlns: namespace } );
-
-			const viewSvg = converter.domToView( svg );
-
-			expect( viewSvg.getAttribute( 'xmlns' ) ).to.equal( namespace );
-		} );
-
 		describe( 'it should clear whitespaces', () => {
 			it( 'at the beginning of block element', () => {
 				const domDiv = createElement( document, 'div', {}, [

+ 9 - 0
packages/ckeditor5-engine/tests/view/domconverter/view-to-dom.js

@@ -174,6 +174,15 @@ describe( 'DomConverter', () => {
 			expect( domTextNode.data ).to.equal( 'foo' );
 		} );
 
+		it( 'should create namespaced elements', () => {
+			const namespace = 'http://www.w3.org/2000/svg';
+			const viewSvg = new ViewElement( 'svg', { xmlns: namespace } );
+
+			const domSvg = converter.viewToDom( viewSvg, document );
+
+			expect( domSvg.createSVGRect ).to.be.a( 'function' );
+		} );
+
 		describe( 'it should convert spaces to  ', () => {
 			it( 'at the beginning of each container element', () => {
 				const viewDiv = new ViewContainerElement( 'div', null, [