bem / html-differ

Сompares two HTML
http://bem.info/tools/testing/html-differ/
MIT License
212 stars 45 forks source link

isEqual seems broken #156

Closed mordrax closed 6 years ago

mordrax commented 6 years ago

It seems isEqual doesn't do what I think it does:

b = new HtmlDiffer()
HtmlDiffer {options: {…}}

b.diffHtml("<div></div>", "<span></span>")
(7) [{…}, {…}, {…}, {…}, {…}, {…}, {…}]

b.isEqual()
true

Shouldn't this be false? I'm getting this no matter what html I put in.

mordrax commented 6 years ago

Stupid me, using isEqual without argument.

Sucks that it defaults to true rather than throwing an error. Silently passes all my tests.