PHP Classes

File: public/js/tinymce/src/core/src/test/js/browser/dom/TrimHtmlTest.js

Recommend this page to a friend!
  Classes of Abed Nego Ragil Putra   GoLavaCMS   public/js/tinymce/src/core/src/test/js/browser/dom/TrimHtmlTest.js   Download  
File: public/js/tinymce/src/core/src/test/js/browser/dom/TrimHtmlTest.js
Role: Auxiliary data
Content type: text/plain
Description: Auxiliary data
Class: GoLavaCMS
Publish content on Web pages with SEO support
Author: By
Last change:
Date: 6 years ago
Size: 1,333 bytes
 

Contents

Class file image Download
test( 'browser.tinymce.core.dom.TrimHtmlTest', [ 'ephox.agar.api.RawAssertions', 'global!document', 'tinymce.core.Editor', 'tinymce.core.EditorManager', 'tinymce.core.dom.DomSerializer', 'tinymce.core.dom.TrimHtml', 'tinymce.core.text.Zwsp' ], function (RawAssertions, document, Editor, EditorManager, DomSerializer, TrimHtml, Zwsp) { var serializer = DomSerializer({}, new Editor('id', {}, EditorManager)); RawAssertions.assertEq('Should be unchanged', '<p id="a" data-mce-abc="1">a</p>', TrimHtml.trimInternal(serializer, '<p id="a" data-mce-abc="1">a</p>')); RawAssertions.assertEq('Should not have internal attr', '<p>a</p>', TrimHtml.trimInternal(serializer, '<p data-mce-selected="1">a</p>')); RawAssertions.assertEq('Should not trim zwsp', '<p>a' + Zwsp.ZWSP + 'b</p>', TrimHtml.trimInternal(serializer, '<p>a' + Zwsp.ZWSP + 'b</p>')); RawAssertions.assertEq('Should be unchanged', '<p id="a" data-mce-abc="1">a</p>', TrimHtml.trimExternal(serializer, '<p id="a" data-mce-abc="1">a</p>')); RawAssertions.assertEq('Should not have internal attr', '<p>a</p>', TrimHtml.trimExternal(serializer, '<p data-mce-selected="1">a</p>')); RawAssertions.assertEq('Should not have zwsp', '<p>ab</p>', TrimHtml.trimExternal(serializer, '<p>a' + Zwsp.ZWSP + 'b</p>')); } );