Browse Source

Tests: Updated conditions too (after changing error names).

Piotrek Koszuliński 5 years ago
parent
commit
32dc1038d4

+ 1 - 1
packages/ckeditor5-core/tests/_utils-tests/articlepluginset.js

@@ -45,7 +45,7 @@ describe( 'ArticlePluginSet', () => {
 		editorElement.remove();
 	} );
 
-	it( 'should be loaded', () => {
+	it.only( 'should be loaded', () => {
 		expect( editor.plugins.get( ArticlePluginSet ) ).to.be.instanceOf( ArticlePluginSet );
 	} );
 

+ 3 - 3
packages/ckeditor5-core/tests/context.js

@@ -93,7 +93,7 @@ describe( 'Context', () => {
 
 			expect( caughtError ).to.instanceof( CKEditorError );
 			expect( caughtError.message )
-				.match( /^context-initplugins-invalid-plugin: Only plugin marked as a ContextPlugin is allowed./ );
+				.match( /^context-initplugins-invalid-plugin:/ );
 		} );
 
 		it( 'should throw when plugin added to the context is not marked as a ContextPlugin (Function)', async () => {
@@ -109,7 +109,7 @@ describe( 'Context', () => {
 
 			expect( caughtError ).to.instanceof( CKEditorError );
 			expect( caughtError.message )
-				.match( /^context-initplugins-invalid-plugin: Only plugin marked as a ContextPlugin is allowed./ );
+				.match( /^context-initplugins-invalid-plugin:/ );
 		} );
 
 		it( 'should throw when plugin is added to the context by name', async () => {
@@ -123,7 +123,7 @@ describe( 'Context', () => {
 
 			expect( caughtError ).to.instanceof( CKEditorError );
 			expect( caughtError.message )
-				.match( /^context-initplugins-constructor-only: Only constructor is allowed as a Context plugin./ );
+				.match( /^context-initplugins-constructor-only:/ );
 		} );
 
 		it( 'should not throw when plugin as a function, marked as a ContextPlugin is added to the context', async () => {