Fix accidentally renamed hint group

This commit is contained in:
Olmo Kramer 2018-07-05 00:57:08 +02:00
parent 9f5f52360c
commit daa8bc0507
No known key found for this signature in database
GPG Key ID: BE09591F4AB66337
3 changed files with 11 additions and 11 deletions

View File

@ -2542,7 +2542,7 @@ Default:
* +pass:[audio]+ * +pass:[audio]+
* +pass:[img]+ * +pass:[img]+
* +pass:[video]+ * +pass:[video]+
- +pass:[urls]+: - +pass:[url]+:
* +pass:[[src]]+ * +pass:[[src]]+
* +pass:[[href]]+ * +pass:[[href]]+

View File

@ -1071,7 +1071,7 @@ hints.selectors:
- 'audio' - 'audio'
- 'img' - 'img'
- 'video' - 'video'
urls: url:
- '[src]' - '[src]'
- '[href]' - '[href]'
inputs: inputs:

View File

@ -146,18 +146,18 @@ class SelectionAndFilterTests:
TESTS = [ TESTS = [
('<foo />', []), ('<foo />', []),
('<foo bar="baz"/>', []), ('<foo bar="baz"/>', []),
('<foo href="baz"/>', ['urls']), ('<foo href="baz"/>', ['url']),
('<foo src="baz"/>', ['urls']), ('<foo src="baz"/>', ['url']),
('<a />', ['all']), ('<a />', ['all']),
('<a href="foo" />', ['all', 'links', 'urls']), ('<a href="foo" />', ['all', 'links', 'url']),
('<a href="javascript://foo" />', ['all', 'links', 'urls']), ('<a href="javascript://foo" />', ['all', 'links', 'url']),
('<area />', ['all']), ('<area />', ['all']),
('<area href="foo" />', ['all', 'links', 'urls']), ('<area href="foo" />', ['all', 'links', 'url']),
('<link />', ['all']), ('<link />', ['all']),
('<link href="foo" />', ['all', 'links', 'urls']), ('<link href="foo" />', ['all', 'links', 'url']),
('<textarea />', ['all', 'inputs']), ('<textarea />', ['all', 'inputs']),
('<select />', ['all']), ('<select />', ['all']),
@ -173,7 +173,7 @@ class SelectionAndFilterTests:
('<input type="search" />', ['inputs', 'all']), ('<input type="search" />', ['inputs', 'all']),
('<button />', ['all']), ('<button />', ['all']),
('<button href="foo" />', ['all', 'urls']), ('<button href="foo" />', ['all', 'url']),
# We can't easily test <frame>/<iframe> as they vanish when setting # We can't easily test <frame>/<iframe> as they vanish when setting
# them via QWebFrame::setHtml... # them via QWebFrame::setHtml...
@ -182,10 +182,10 @@ class SelectionAndFilterTests:
('<p onmousedown="foo" foo="bar"/>', ['all']), ('<p onmousedown="foo" foo="bar"/>', ['all']),
('<p role="option" foo="bar"/>', ['all']), ('<p role="option" foo="bar"/>', ['all']),
('<p role="button" foo="bar"/>', ['all']), ('<p role="button" foo="bar"/>', ['all']),
('<p role="button" href="bar"/>', ['all', 'urls']), ('<p role="button" href="bar"/>', ['all', 'url']),
] ]
GROUPS = ['all', 'links', 'images', 'urls', 'inputs'] GROUPS = ['all', 'links', 'images', 'url', 'inputs']
COMBINATIONS = list(itertools.product(TESTS, GROUPS)) COMBINATIONS = list(itertools.product(TESTS, GROUPS))