From cff322d499962d79e651ba19fb2193a81eb1442d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Maciej=20Go=C5=82aszewski?= Date: Wed, 16 Jan 2019 16:30:08 +0100 Subject: [PATCH 1/2] Add memory leak test. --- tests/ckeditor.js | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/tests/ckeditor.js b/tests/ckeditor.js index 7e8ed050..3b25fd1d 100644 --- a/tests/ckeditor.js +++ b/tests/ckeditor.js @@ -7,6 +7,7 @@ import BalloonEditor from '../src/ckeditor'; import BaseBalloonEditor from '@ckeditor/ckeditor5-editor-balloon/src/ballooneditor'; +import { describeMemoryUsage, testMemoryUsage } from '@ckeditor/ckeditor5-core/tests/_utils/memory'; describe( 'BalloonEditor build', () => { let editor, editorElement; @@ -22,7 +23,7 @@ describe( 'BalloonEditor build', () => { editorElement.remove(); } ); - describe( 'buid', () => { + describe( 'build', () => { it( 'contains plugins', () => { expect( BalloonEditor.builtinPlugins ).to.not.be.empty; } ); @@ -155,4 +156,10 @@ describe( 'BalloonEditor build', () => { expect( editor.getData() ).to.equal( data ); } ); } ); + + describeMemoryUsage( () => { + testMemoryUsage( + 'should not grow on multiple create/destroy', + () => BalloonEditor.create( document.querySelector( '#mem-editor' ) ) ); + } ); } ); From be435a8de7775c6a73968d2c4d5fb768952b2e7b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Maciej=20Go=C5=82aszewski?= Date: Tue, 22 Jan 2019 10:33:32 +0100 Subject: [PATCH 2/2] Add missing ckeditor5-core dependency. --- package.json | 1 + 1 file changed, 1 insertion(+) diff --git a/package.json b/package.json index 87e2b214..138e5335 100644 --- a/package.json +++ b/package.json @@ -30,6 +30,7 @@ "@ckeditor/ckeditor5-basic-styles": "^10.1.0", "@ckeditor/ckeditor5-block-quote": "^10.1.1", "@ckeditor/ckeditor5-ckfinder": "^10.0.0", + "@ckeditor/ckeditor5-core": "^11.1.0", "@ckeditor/ckeditor5-dev-utils": "^11.0.1", "@ckeditor/ckeditor5-dev-webpack-plugin": "^7.0.1", "@ckeditor/ckeditor5-easy-image": "^10.0.4",