Skip to content

Commit 841e67c

Browse files
author
Marc DM
committed
updated test comment
1 parent 4a7adf2 commit 841e67c

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

html5lib/tests/test_treewalkers.py

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -342,7 +342,12 @@ def runTreewalkerEditTest(intext, expected, attrs_to_add, tree):
342342
def test_treewalker_six_mix():
343343
"""Str/Unicode mix. If str attrs added to tree"""
344344

345-
# ToDo: Find a better way to specify that the attribute value is a bytestring
345+
# On Python 2.x string literals are of type str. Unless, like this
346+
# file, the programmer imports unicode_literals from __future__.
347+
# In that case, string literals become objects of type unicode.
348+
349+
# This test simulates a Py2 user, modifying attributes on a document
350+
# fragment but not using the u'' syntax nor importing unicode_literals
346351
sm_tests = [
347352
('<a href="http://example.com">Example</a>',
348353
[(str('class'), str('test123'))],

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy