Skip to content

Commit

Permalink
#973 added assertRaises
Browse files Browse the repository at this point in the history
  • Loading branch information
olegush committed Dec 3, 2019
1 parent 7cffd04 commit d267c74
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions shopelectro/tests/tests_html.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
from django.template.loader import render_to_string

from html5validate import validate
from html5lib import html5parser


@tag('fast')
Expand All @@ -27,10 +28,11 @@ def test_valid_example(self):
)
validate(render_to_string(filepath))

@unittest.expectedFailure
#@unittest.expectedFailure
def test_invalid_example(self):
filepath = os.path.join(
settings.TEMPLATE_ASSETS_DIR,
'invalid_markup_example.html'
)
validate(render_to_string(filepath))
with self.assertRaises(html5parser.ParseError):
validate(render_to_string(filepath))

0 comments on commit d267c74

Please sign in to comment.