(GH-40)'] = function () {
+ var parser = new Parser(treeAdapter),
+ serializer = new Serializer(treeAdapter),
+ src = 'second
',
+ fragment = parser.parseFragment(src),
+ actual = serializer.serialize(fragment);
+
+ assert.strictEqual(actual, src, TestUtils.getStringDiffMsg(actual, src));
+ };
+
+ //html5lib test suite
+ //------------------------------------------------------------------------------
function getFullTestName(test) {
return ['Parser - ', test.idx, '.', test.setName, ' - ', test.input].join('');
}
diff --git a/test/fixtures/serializer_test.js b/test/fixtures/serializer_test.js
index dd6377be..9aa22270 100644
--- a/test/fixtures/serializer_test.js
+++ b/test/fixtures/serializer_test.js
@@ -44,17 +44,17 @@ exports['Regression - SYSTEM-only doctype serialization'] = function () {
exports['Regression - Escaping of doctypes with quotes in them'] = function () {
var htmlStrs = [
- '' +
- '',
+ '' +
+ '',
- '' +
- '',
+ '' +
+ '',
- '' +
- ''
+ '' +
+ ''
],
parser = new Parser(),
serializer = new Serializer();
@@ -93,24 +93,24 @@ exports['Regression - new line in tag'] = function () {
exports['Options - encodeHtmlEntities'] = function () {
var testHtmlCases = [
{
- options: { encodeHtmlEntities: true },
+ options: {encodeHtmlEntities: true},
src: '&',
expected: '&'
},
{
- options: { encodeHtmlEntities: false },
+ options: {encodeHtmlEntities: false},
src: '&',
expected: '&'
},
{
- options: { encodeHtmlEntities: true },
+ options: {encodeHtmlEntities: true},
src: '',
expected: ''
},
{
- options: { encodeHtmlEntities: false },
+ options: {encodeHtmlEntities: false},
src: '',
expected: ''
}