xxx is ignored in browsers becuase it is the first line in comment, subsequent lines won't be ignored.
Note also that HtmlUniti doesn't parse correct comments, because of the issue raised for EventTest#testCommentInEventHandlerDeclaration because of 'non-normalized' values during parsing.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
htmlunit already behaves correctly when script contains multiple lines. Here the problem seems just to be with an useless script with a single line starting by a comment.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Logged In: YES
user_id=402164
Originator: NO
in your example xxx is ignored by a "normal" browser. Correct?
Logged In: YES
user_id=950730
Originator: NO
xxx is ignored in browsers becuase it is the first line in comment, subsequent lines won't be ignored.
Note also that HtmlUniti doesn't parse correct comments, because of the issue raised for EventTest#testCommentInEventHandlerDeclaration because of 'non-normalized' values during parsing.
Logged In: YES
user_id=402164
Originator: NO
htmlunit already behaves correctly when script contains multiple lines. Here the problem seems just to be with an useless script with a single line starting by a comment.
Logged In: YES
user_id=950730
Originator: NO
Sorry, you are right about correct handling of comments inside <script>.
Will fix this 'incorrectness' handling soon.
Logged In: YES
user_id=402164
Originator: NO
Now fixed in SVN.
Logged In: YES
user_id=1400162
Originator: YES
Almost :)
My first case above still fails: <script><!-- </script>
Logged In: YES
user_id=402164
Originator: NO
Case now unit tested and fixed too. Thanks.