test.SimpleTestCase.assertInHTML()

SimpleTestCase.assertInHTML(needle, haystack, count=None, msg_prefix='') [source]

Asserts that the HTML fragment needle is contained in the haystack one.

If the count integer argument is specified, then additionally the number of needle occurrences will be strictly verified.

Whitespace in most cases is ignored, and attribute ordering is not significant. The passed-in arguments must be valid HTML.

doc_Django
2016-10-09 18:40:05
Comments
Leave a Comment

Please login to continue.