Tests: Added missing feature tests.

parent 51a68727
...@@ -90,6 +90,8 @@ describe( 'DecoupledDocumentEditor build', () => { ...@@ -90,6 +90,8 @@ describe( 'DecoupledDocumentEditor build', () => {
'<p>', '<p>',
'<strong>Test:strong</strong>', '<strong>Test:strong</strong>',
'<i>Test:i</i>', '<i>Test:i</i>',
'<u>Test:u</u>',
'<s>Test:s</s>',
'</p>' '</p>'
].join( '' ); ].join( '' );
...@@ -148,6 +150,34 @@ describe( 'DecoupledDocumentEditor build', () => { ...@@ -148,6 +150,34 @@ describe( 'DecoupledDocumentEditor build', () => {
editor.setData( data ); editor.setData( data );
expect( editor.getData() ).to.equal( data ); expect( editor.getData() ).to.equal( data );
} ); } );
it( 'font size works', () => {
const data = '<p><span class="text-big">foo</span></p>';
editor.setData( data );
expect( editor.getData() ).to.equal( data );
} );
it( 'font family works', () => {
const data = '<p><span style="font-family:Georgia, serif;">foo</span></p>';
editor.setData( data );
expect( editor.getData() ).to.equal( data );
} );
it( 'highlight works', () => {
const data = '<p><mark class="marker-green">foo</mark></p>';
editor.setData( data );
expect( editor.getData() ).to.equal( data );
} );
it( 'alignment works', () => {
const data = '<p style="text-align:right;">foo</p>';
editor.setData( data );
expect( editor.getData() ).to.equal( data );
} );
} ); } );
describe( 'config', () => { describe( 'config', () => {
......
...@@ -47,7 +47,7 @@ iterations of the project. Stay tuned for some updates soon!</p>`; ...@@ -47,7 +47,7 @@ iterations of the project. Stay tuned for some updates soon!</p>`;
DecoupledDocumentEditor DecoupledDocumentEditor
.create( editorData, { .create( editorData, {
toolbarContainer: '.toolbar-container', toolbarContainer: '.toolbar-container',
editableContainer: '.editable-container', editableContainer: '.editable-container'
} ) } )
.then( editor => { .then( editor => {
window.editor = editor; window.editor = editor;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment