Skip to content

Commit

Permalink
Adjust the test expectation with htmlparser2 doc to self close the div
Browse files Browse the repository at this point in the history
  • Loading branch information
CarsonF committed Aug 22, 2024
1 parent ab230ef commit 72f03c7
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions test/run.js
Original file line number Diff line number Diff line change
Expand Up @@ -28,10 +28,10 @@ it('juice(html)', function() {
});

it('juice(document) with htmlparser2', function() {
var dom = htmlparser2.parseDOM('<style>div{color:red;}</style><div/>');
var dom = htmlparser2.parseDocument('<style>div{color:red;}</style><div/>');
var $ = cheerio.load(dom, {xml:true});

var expected = '<div style="color: red;"></div>';
var expected = '<div style="color: red;"/>';
juice.juiceDocument($);
var actual = $.html();
assert.equal(utils.normalizeLineEndings(actual.trim()), utils.normalizeLineEndings(expected.trim()));
Expand Down

0 comments on commit 72f03c7

Please sign in to comment.