Add assertHTMLEqual and related assert methods to TestCase
|Reported by:||carljm||Owned by:||gregmuellegger|
|Has patch:||yes||Needs documentation:||no|
|Needs tests:||no||Patch needs improvement:||no|
This need came out of the form-rendering GSoC branch, due to a bunch of existing form rendering tests that test against HTML strings. Switching to template-based rendering would often cause spurious test failures due to irrelevant differences in HTML tag attribute ordering or whitespace. So in the branch we've added assertHTMLEqual and assertHTMLNotEqual methods, as well as a boolean "html" argument to assertContains.
These additions can be committed separately from the rest of the branch, but need to be split out first.
Most up-to-date code for the branch is at https://github.com/carljm/django/compare/master...soc2011%2Fform-rendering
Change History (10)
comment:2 Changed 4 years ago by gregmuellegger
- Owner changed from nobody to gregmuellegger
- Status changed from new to assigned