Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Z
Zope
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
Zope
Commits
e37dbe4f
Commit
e37dbe4f
authored
Apr 06, 2001
by
Fred Drake
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Revise a test that requires "<tag attr=>" to be accepted -- it is not!
Add a check to ensure it raises an HTMLParseError.
parent
96b06b29
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
6 additions
and
4 deletions
+6
-4
lib/python/TAL/test/test_htmlparser.py
lib/python/TAL/test/test_htmlparser.py
+3
-2
lib/python/TAL/tests/test_htmlparser.py
lib/python/TAL/tests/test_htmlparser.py
+3
-2
No files found.
lib/python/TAL/test/test_htmlparser.py
View file @
e37dbe4f
...
@@ -162,8 +162,8 @@ text
...
@@ -162,8 +162,8 @@ text
(
"c"
,
"yyy
\
t
\
n
yyy"
),
(
"c"
,
"yyy
\
t
\
n
yyy"
),
(
"d"
,
"
\
t
xyz
\
n
"
)])
(
"d"
,
"
\
t
xyz
\
n
"
)])
])
])
self
.
_run_check
(
"""<a b='' c=""
d=
>"""
,
[
self
.
_run_check
(
"""<a b='' c="">"""
,
[
(
"starttag"
,
"a"
,
[(
"b"
,
""
),
(
"c"
,
""
)
,
(
"d"
,
""
)
]),
(
"starttag"
,
"a"
,
[(
"b"
,
""
),
(
"c"
,
""
)]),
])
])
def
check_attr_entity_replacement
(
self
):
def
check_attr_entity_replacement
(
self
):
...
@@ -216,6 +216,7 @@ text
...
@@ -216,6 +216,7 @@ text
self
.
_parse_error
(
"<a foo='bar"
)
self
.
_parse_error
(
"<a foo='bar"
)
self
.
_parse_error
(
"<a foo='>'"
)
self
.
_parse_error
(
"<a foo='>'"
)
self
.
_parse_error
(
"<a foo='>"
)
self
.
_parse_error
(
"<a foo='>"
)
self
.
_parse_error
(
"<a foo=>"
)
def
check_declaration_junk_chars
(
self
):
def
check_declaration_junk_chars
(
self
):
self
.
_parse_error
(
"<!DOCTYPE foo $ >"
)
self
.
_parse_error
(
"<!DOCTYPE foo $ >"
)
...
...
lib/python/TAL/tests/test_htmlparser.py
View file @
e37dbe4f
...
@@ -162,8 +162,8 @@ text
...
@@ -162,8 +162,8 @@ text
(
"c"
,
"yyy
\
t
\
n
yyy"
),
(
"c"
,
"yyy
\
t
\
n
yyy"
),
(
"d"
,
"
\
t
xyz
\
n
"
)])
(
"d"
,
"
\
t
xyz
\
n
"
)])
])
])
self
.
_run_check
(
"""<a b='' c=""
d=
>"""
,
[
self
.
_run_check
(
"""<a b='' c="">"""
,
[
(
"starttag"
,
"a"
,
[(
"b"
,
""
),
(
"c"
,
""
)
,
(
"d"
,
""
)
]),
(
"starttag"
,
"a"
,
[(
"b"
,
""
),
(
"c"
,
""
)]),
])
])
def
check_attr_entity_replacement
(
self
):
def
check_attr_entity_replacement
(
self
):
...
@@ -216,6 +216,7 @@ text
...
@@ -216,6 +216,7 @@ text
self
.
_parse_error
(
"<a foo='bar"
)
self
.
_parse_error
(
"<a foo='bar"
)
self
.
_parse_error
(
"<a foo='>'"
)
self
.
_parse_error
(
"<a foo='>'"
)
self
.
_parse_error
(
"<a foo='>"
)
self
.
_parse_error
(
"<a foo='>"
)
self
.
_parse_error
(
"<a foo=>"
)
def
check_declaration_junk_chars
(
self
):
def
check_declaration_junk_chars
(
self
):
self
.
_parse_error
(
"<!DOCTYPE foo $ >"
)
self
.
_parse_error
(
"<!DOCTYPE foo $ >"
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment