Преглед на файлове

Tests work without focus.

Piotr Jasiun преди 9 години
родител
ревизия
6c90108beb
променени са 2 файла, в които са добавени 2 реда и са изтрити 3 реда
  1. 0 1
      packages/ckeditor5-engine/tests/__template__.html
  2. 2 2
      packages/ckeditor5-engine/tests/editingcontroller.js

+ 0 - 1
packages/ckeditor5-engine/tests/__template__.html

@@ -1,2 +1 @@
-<input type="text" id="focusPlaceholder" />
 <div contenteditable="true" id="editor"></div>

+ 2 - 2
packages/ckeditor5-engine/tests/editingcontroller.js

@@ -131,8 +131,6 @@ describe( 'EditingController', () => {
 		} );
 
 		beforeEach( () => {
-			document.getElementById( 'focusPlaceholder' ).focus();
-
 			model.selection.removeAllRanges();
 			modelRoot.removeChildren( 0, modelRoot.getChildCount() );
 
@@ -192,6 +190,8 @@ describe( 'EditingController', () => {
 				} );
 			} );
 
+			editing.view.focusedEditable = viewRoot;
+
 			const domSelection = document.getSelection();
 			domSelection.removeAllRanges();
 			const domBar = domRoot.childNodes[ 2 ].childNodes[ 0 ];