ソースを参照

Aligned code to the changes in engine.

Kamil Piechaczek 7 年 前
コミット
d5707ceea0

+ 2 - 3
packages/ckeditor5-image/tests/imagecaption/imagecaptionengine.js

@@ -465,12 +465,11 @@ describe( 'ImageCaptionEngine', () => {
 			} );
 
 			it( 'undo should work after inserting the image', () => {
-				const image = new ModelElement( 'image' );
-				image.setAttribute( 'src', '/foo.png' );
-
 				setModelData( model, '<paragraph>foo[]</paragraph>' );
 
 				model.change( writer => {
+					const image = writer.createElement( 'image', { src: '/foo.png' } );
+
 					writer.insert( image, doc.getRoot() );
 				} );