mirror of https://github.com/scrapy/scrapy.git
test: address Adrian+syncrain PR feedback
- remove first docstring line (Adrian: unnecessary) - replace weak isinstance assert with no-op call - keep Cython function mention (Adrian: wording is great)
This commit is contained in:
parent
099b6e47e0
commit
e787fbb139
|
|
@ -314,13 +314,10 @@ def test_xml_entity_expansion():
|
|||
|
||||
|
||||
def test_sitemap_non_string_tag():
|
||||
"""Regression test for non-string elem.tag crashing _get_tag_name.
|
||||
|
||||
With recover=True and resolve_entities=False, libxml2 >= 2.14.6 (used
|
||||
"""With recover=True and resolve_entities=False, libxml2 >= 2.14.6 (used
|
||||
by lxml >= 6.1.1) preserves undeclared entity reference nodes whose
|
||||
.tag is a non-string `Cython function` object instead of a str.
|
||||
.tag is a non-string ``Cython function`` object instead of a ``str``.
|
||||
_get_tag_name must handle this gracefully instead of raising
|
||||
AttributeError.
|
||||
"""
|
||||
results = list(Sitemap(b"<url>&k;"))
|
||||
assert isinstance(results, list)
|
||||
list(Sitemap(b"<url>&k;"))
|
||||
|
|
|
|||
Loading…
Reference in New Issue