浏览代码

Aligned code to the changes in engine.

Kamil Piechaczek 7 年之前
父节点
当前提交
d5707ceea0
共有 1 个文件被更改,包括 2 次插入3 次删除
  1. 2 3
      packages/ckeditor5-image/tests/imagecaption/imagecaptionengine.js

+ 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() );
 				} );