We need a better way to test the parser. The issue is everytime a single whitespace changes the test fail. Although the result is still valid html and equivalent to the expected result, since we are doing a string comparison, they don't match anymore.
So, the tests are currently failing, and I'm gonna keep them that way until either we find a better way to test, or all the planed features for the Avant release are done and we really need the tests to be ok.
The idea of posting this issue here is to try to gather ideas of how to do the tests. I'm currently thinking about parsing the generated html and comparing the nodes.
We are using XmlDiff to compare the expected and the actual results. It's not space sensitive as it compares nodes, attributes and attribute values. Tests are all passing now, but a lot of tests still need to be rewritten though.
We need a better way to test the parser. The issue is everytime a single whitespace changes the test fail. Although the result is still valid html and equivalent to the expected result, since we are doing a string comparison, they don't match anymore.
So, the tests are currently failing, and I'm gonna keep them that way until either we find a better way to test, or all the planed features for the Avant release are done and we really need the tests to be ok.
The idea of posting this issue here is to try to gather ideas of how to do the tests. I'm currently thinking about parsing the generated html and comparing the nodes.
Do you have a better idea? Please share it!