mirror of
https://github.com/ArchiveBox/ArchiveBox
synced 2024-11-26 06:00:22 +00:00
when checking link invariants, check for regex match as well
This commit is contained in:
parent
fa6f53f2af
commit
b4dc80b0a7
1 changed files with 1 additions and 0 deletions
|
@ -677,6 +677,7 @@ def check_link_structure(link):
|
|||
assert isinstance(link, dict)
|
||||
assert isinstance(link.get('url'), str)
|
||||
assert len(link['url']) > 2
|
||||
assert len(re.findall(URL_REGEX, link['url'])) == 1
|
||||
|
||||
|
||||
def check_links_structure(links):
|
||||
|
|
Loading…
Reference in a new issue