mirror of
https://github.com/Hopiu/linkchecker.git
synced 2026-04-11 01:50:59 +00:00
commit
42333362aa
6 changed files with 22 additions and 4 deletions
|
|
@ -23,7 +23,7 @@ Features
|
|||
- Cookie support
|
||||
- HTML5 support
|
||||
- a command line and web interface
|
||||
- various check plugins available, eg. HTML syntax and antivirus checks.
|
||||
- various check plugins available
|
||||
|
||||
Installation
|
||||
-------------
|
||||
|
|
|
|||
|
|
@ -56,8 +56,7 @@ Features
|
|||
- honors robots.txt exclusion protocol
|
||||
- Cookie support
|
||||
- HTML5 support
|
||||
- :ref:`Plugin support <man/linkchecker:PLUGINS>` allowing custom page checks. Currently available are
|
||||
HTML and CSS syntax checks, Antivirus checks, and more.
|
||||
- :ref:`Plugin support <man/linkchecker:PLUGINS>` allowing custom page checks
|
||||
- Different interfaces: command line and web interface
|
||||
|
||||
Screenshots
|
||||
|
|
|
|||
|
|
@ -24,7 +24,6 @@ LinkChecker features
|
|||
- support for robots.txt exclusion protocol
|
||||
- support for Cookies
|
||||
- support for HTML5
|
||||
- HTML and CSS syntax check
|
||||
- Antivirus check
|
||||
- a command line and web interface
|
||||
|
||||
|
|
|
|||
|
|
@ -434,6 +434,10 @@ AnchorCheck
|
|||
|
||||
Checks validity of HTML anchors.
|
||||
|
||||
.. note::
|
||||
|
||||
The AnchorCheck plugin is currently broken and is disabled.
|
||||
|
||||
LocationInfo
|
||||
^^^^^^^^^^^^
|
||||
|
||||
|
|
@ -471,6 +475,10 @@ HtmlSyntaxCheck
|
|||
Check the syntax of HTML pages with the online W3C HTML validator. See
|
||||
https://validator.w3.org/docs/api.html.
|
||||
|
||||
.. note::
|
||||
|
||||
The HtmlSyntaxCheck plugin is currently broken and is disabled.
|
||||
|
||||
HttpHeaderInfo
|
||||
^^^^^^^^^^^^^^
|
||||
|
||||
|
|
|
|||
|
|
@ -26,8 +26,16 @@ from ..htmlutil import linkparse
|
|||
class AnchorCheck(_ContentPlugin):
|
||||
"""Checks validity of HTML anchors."""
|
||||
|
||||
def __init__(self, config):
|
||||
"""Initialize plugin."""
|
||||
super().__init__(config)
|
||||
log.warn(
|
||||
LOG_PLUGIN, _("Anchor check plugin is broken. Fixes welcome.")
|
||||
)
|
||||
|
||||
def applies_to(self, url_data):
|
||||
"""Check for HTML anchor existence."""
|
||||
return False # XXX Plugin disabled
|
||||
return url_data.is_html() and url_data.anchor
|
||||
|
||||
def check(self, url_data):
|
||||
|
|
|
|||
|
|
@ -16,6 +16,8 @@
|
|||
"""
|
||||
Test html anchor parsing and checking.
|
||||
"""
|
||||
import pytest
|
||||
|
||||
from . import LinkCheckTest
|
||||
from .httpserver import HttpServerTest
|
||||
|
||||
|
|
@ -25,6 +27,7 @@ class TestAnchor(LinkCheckTest):
|
|||
Test anchor checking of HTML pages.
|
||||
"""
|
||||
|
||||
@pytest.mark.xfail(strict=True)
|
||||
def test_anchor(self):
|
||||
confargs = {"enabledplugins": ["AnchorCheck"]}
|
||||
url = "file://%(curdir)s/%(datadir)s/anchor.html" % self.get_attrs()
|
||||
|
|
@ -46,6 +49,7 @@ class TestHttpAnchor(HttpServerTest):
|
|||
Test checking of HTML pages containing links to anchors served over http.
|
||||
"""
|
||||
|
||||
@pytest.mark.xfail(strict=True)
|
||||
def test_anchor_html(self):
|
||||
confargs = dict(enabledplugins=["AnchorCheck"], recursionlevel=1)
|
||||
self.file_test("http_anchor.html", confargs=confargs)
|
||||
|
|
|
|||
Loading…
Reference in a new issue