Crawl HTML attributes in deterministic order

Fixes #17.
This commit is contained in:
Marius Gedminas 2017-02-01 19:19:53 +02:00
parent 5a346bae66
commit 743a5f31cb
2 changed files with 1 additions and 2 deletions

View file

@ -208,7 +208,7 @@ class LinkFinder (TagFinder):
self.base_ref = attrs.get_true("href", u'')
tagattrs = self.tags.get(tag, self.universal_attrs)
# parse URLs in tag (possibly multiple URLs in CSS styles)
for attr in tagattrs.intersection(attrs):
for attr in sorted(tagattrs.intersection(attrs)):
if tag == "meta" and not is_meta_url(attr, attrs):
continue
if tag == "form" and not is_form_get(attr, attrs):

View file

@ -29,7 +29,6 @@ class TestHttp (HttpServerTest):
super(TestHttp, self).__init__(methodName=methodName)
self.handler = CookieRedirectHttpRequestHandler
@pytest.mark.xfail(reason="fails non-deterministically")
def test_html (self):
confargs = dict(recursionlevel=1)
self.file_test("http.html", confargs=confargs)