8
0
Pārlūkot izejas kodu

Tests: provided manual test for unicode characters.

Szymon Cofalik 9 gadi atpakaļ
vecāks
revīzija
e3b1c6858c

+ 8 - 0
packages/ckeditor5-typing/tests/manual/unicode.html

@@ -0,0 +1,8 @@
+<head>
+	<link rel="stylesheet" href="%APPS_DIR%ckeditor/build/modules/amd/theme/ckeditor.css">
+</head>
+
+<div id="editor">
+	<p>Some surrogate pair characters: 💩💩 and 𨭎𨭎</p>
+	<p>Some base characters with combining marks: a̻̐ and z͙ͤͣ</p>
+</div>

+ 19 - 0
packages/ckeditor5-typing/tests/manual/unicode.js

@@ -0,0 +1,19 @@
+/**
+ * @license Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md.
+ */
+
+/* globals console, window, document */
+
+import ClassicEditor from '/ckeditor5/editor-classic/classic.js';
+
+ClassicEditor.create( document.querySelector( '#editor' ), {
+	features: [ 'enter', 'typing', 'paragraph' ],
+	toolbar: []
+} )
+	.then( editor => {
+		window.editor = editor;
+	} )
+	.catch( err => {
+		console.error( err.stack );
+	} );

+ 29 - 0
packages/ckeditor5-typing/tests/manual/unicode.md

@@ -0,0 +1,29 @@
+@bender-ui: collapsed
+
+## Unicode support
+
+### Selection
+
+1. Put caret somewhere before surrogate pair characters.
+2. Using right arrow key move caret to the end of paragraph.
+3. Caret should be placed after each character.
+4. No errors in console.
+5. Do the same but make selection using mouse.
+6. Do the same for combined marks. Note that some browsers (i.e. Chrome) forbid putting selection between லை and க்கு.
+
+### Removing
+
+1. Put caret at the end of first paragraph.
+2. Start removing surrogate pair characters using backspace.
+3. Characters should be removed one by one.
+
+
+1. Put caret at the end of second paragraph.
+2. Start removing combined characters using backspace.
+3. Combining mark and base characters should be removed separately (not at once).
+
+
+1. You may need to refresh test if you removed too many combined characters.
+2. Put caret before combined character.
+3. Start removing combined characters using delete key.
+4. Combining marks should be removed together with base characters.