diff --git a/django/contrib/markup/tests.py b/django/contrib/markup/tests.py index 6e7beaeb2f..9a96f8cda4 100644 --- a/django/contrib/markup/tests.py +++ b/django/contrib/markup/tests.py @@ -61,8 +61,15 @@ Paragraph 2 with a link_ t = Template("{{ rest_content|restructuredtext }}") rendered = t.render(Context(locals())).strip() if docutils: - self.assertEqual(rendered, """
Paragraph 1
+ # Different versions of docutils return slightly different HTML + try: + # Docutils v0.4 and earlier + self.assertEqual(rendered, """Paragraph 1
Paragraph 2 with a link
""") + except AssertionError, e: + # Docutils from SVN (which will become 0.5) + self.assertEqual(rendered, """Paragraph 1
+Paragraph 2 with a link
""") else: self.assertEqual(rendered, rest_content)