Skip to content

Commit

Permalink
fix #139
Browse files Browse the repository at this point in the history
  • Loading branch information
Knio committed Jul 25, 2022
1 parent 647fa2f commit 3e16bf3
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
1 change: 1 addition & 0 deletions dominate/tags.py
Original file line number Diff line number Diff line change
Expand Up @@ -596,6 +596,7 @@ class sup(html_tag):


class i(html_tag):
is_inline = True
'''
The i element represents a span of text in an alternate voice or mood, or
otherwise offset from the normal prose in a manner indicating a different
Expand Down
3 changes: 3 additions & 0 deletions tests/test_html.py
Original file line number Diff line number Diff line change
Expand Up @@ -327,6 +327,9 @@ def test_pretty():
assert span('hi', br(__inline=False), 'there').render() == \
'''<span>hi\n <br>there\n</span>'''

assert p('goodbye ', i('cruel'), ' world').render() == \
'''<p>goodbye <i>cruel</i> world</p>'''


def test_xhtml():
assert head(script('foo'), style('bar')).render(xhtml=True) == '''<head>
Expand Down

0 comments on commit 3e16bf3

Please sign in to comment.