-
This is an
editor instance.
+
This is an
editor instance.
diff --git a/tests/manual/basic-styles.js b/tests/manual/basic-styles.js
index e849929..1db7a2b 100644
--- a/tests/manual/basic-styles.js
+++ b/tests/manual/basic-styles.js
@@ -10,13 +10,14 @@ import Essentials from '@ckeditor/ckeditor5-essentials/src/essentials';
import Paragraph from '@ckeditor/ckeditor5-paragraph/src/paragraph';
import Bold from '../../src/bold';
import Italic from '../../src/italic';
+import Strikethrough from '../../src/strikethrough';
import Underline from '../../src/underline';
import Code from '../../src/code';
ClassicEditor
.create( document.querySelector( '#editor' ), {
- plugins: [ Essentials, Paragraph, Bold, Italic, Underline, Code ],
- toolbar: [ 'bold', 'italic', 'underline', 'code', 'undo', 'redo' ]
+ plugins: [ Essentials, Paragraph, Bold, Italic, Strikethrough, Underline, Code ],
+ toolbar: [ 'bold', 'italic', 'strikethrough', 'underline', 'code', 'undo', 'redo' ]
} )
.then( editor => {
window.editor = editor;
diff --git a/tests/manual/basic-styles.md b/tests/manual/basic-styles.md
index 65f6869..994bbb8 100644
--- a/tests/manual/basic-styles.md
+++ b/tests/manual/basic-styles.md
@@ -1,8 +1,9 @@
## Basic styles
1. The data should be loaded with:
- * italic "This",
- * bold "editor",
+ * italic _"This"_,
+ * bold **"editor"**,
* underline "instance",
- * code "is an".
-2. Test the bold, italic, underline and code features live.
+ * strikethrough ~~"is"~~,
+ * code `"an"`.
+2. Test the bold, italic, strikethrough, underline and code features live.
diff --git a/tests/strikethrough.js b/tests/strikethrough.js
new file mode 100644
index 0000000..69cdcf6
--- /dev/null
+++ b/tests/strikethrough.js
@@ -0,0 +1,98 @@
+/**
+ * @license Copyright (c) 2003-2017, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md.
+ */
+
+/* globals document */
+
+import ClassicTestEditor from '@ckeditor/ckeditor5-core/tests/_utils/classictesteditor';
+import Strikethrough from '../src/strikethrough';
+import StrikethroughEngine from '../src/strikethroughengine';
+import ButtonView from '@ckeditor/ckeditor5-ui/src/button/buttonview';
+import testUtils from '@ckeditor/ckeditor5-core/tests/_utils/utils';
+import { keyCodes } from '@ckeditor/ckeditor5-utils/src/keyboard';
+
+testUtils.createSinonSandbox();
+
+describe( 'Strikethrough', () => {
+ let editor, strikeView;
+
+ beforeEach( () => {
+ const editorElement = document.createElement( 'div' );
+ document.body.appendChild( editorElement );
+
+ return ClassicTestEditor
+ .create( editorElement, {
+ plugins: [ Strikethrough ]
+ } )
+ .then( newEditor => {
+ editor = newEditor;
+
+ strikeView = editor.ui.componentFactory.create( 'strikethrough' );
+ } );
+ } );
+
+ afterEach( () => {
+ return editor.destroy();
+ } );
+
+ it( 'should be loaded', () => {
+ expect( editor.plugins.get( Strikethrough ) ).to.be.instanceOf( Strikethrough );
+ } );
+
+ it( 'should load StrikethroughEngine', () => {
+ expect( editor.plugins.get( StrikethroughEngine ) ).to.be.instanceOf( StrikethroughEngine );
+ } );
+
+ it( 'should register strikethrough feature component', () => {
+ expect( strikeView ).to.be.instanceOf( ButtonView );
+ expect( strikeView.isOn ).to.be.false;
+ expect( strikeView.label ).to.equal( 'Strikethrough' );
+ expect( strikeView.icon ).to.match( /