dart-lang / html

Dart port of html5lib. For parsing HTML/HTML5 with Dart. Works in the client and on the server.

Home Page:https://pub.dev/packages/html

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Tests for errors are not running

natebosch opened this issue · comments

final checkParseErrors = false;

Many of the tests start failing if we enable error checking.

Further, the tests against error only check the number of errors:

if (checkParseErrors) {
expect(parser.errors.length, equals(errors.length),
reason: '\n\nInput:\n$input\n\nExpected errors (${errors.length}):\n'
"${errors.join('\n')}\n\n"
'Actual errors (${parser.errors.length}):\n'
"${parser.errors.map((e) => '$e').join('\n')}");
}

It really should be checking the content too.