mirror of
https://github.com/Hopiu/linkchecker.git
synced 2026-04-28 18:14:42 +00:00
Print NNTP server welcome string as info
This commit is contained in:
parent
2bce793bbc
commit
0b5f525f76
2 changed files with 6 additions and 0 deletions
|
|
@ -92,6 +92,7 @@ class NntpUrl (urlbase.UrlBase):
|
|||
tag=WARN_NNTP_BUSY)
|
||||
if log.is_debug(LOG_CHECK):
|
||||
nntp.set_debuglevel(1)
|
||||
self.add_info(nntp.getwelcome())
|
||||
return nntp
|
||||
|
||||
def can_get_content (self):
|
||||
|
|
|
|||
|
|
@ -23,6 +23,8 @@ from . import LinkCheckTest
|
|||
|
||||
# Change from time to time, as servers tend to get invalid.
|
||||
NNTP_SERVER = "freenews.netfront.net"
|
||||
# info string returned by news server
|
||||
NNTP_INFO = u"200 news.netfront.net InterNetNews NNRP server INN 2.4.6 (20090304 snapshot) ready (posting ok)."
|
||||
|
||||
|
||||
class TestNews (LinkCheckTest):
|
||||
|
|
@ -99,6 +101,7 @@ class TestNews (LinkCheckTest):
|
|||
u"url %s" % url,
|
||||
u"cache key %s" % url,
|
||||
u"real url %s" % url,
|
||||
u"info %s" % NNTP_INFO,
|
||||
u"info News group comp.lang.python found.",
|
||||
u"valid",
|
||||
]
|
||||
|
|
@ -113,6 +116,7 @@ class TestNews (LinkCheckTest):
|
|||
u"url %s" % url,
|
||||
u"cache key %s" % url,
|
||||
u"real url %s" % url,
|
||||
u"info %s" % NNTP_INFO,
|
||||
u"info News group comp.lang.python found.",
|
||||
u"valid",
|
||||
]
|
||||
|
|
@ -136,6 +140,7 @@ class TestNews (LinkCheckTest):
|
|||
u"url %s" % url,
|
||||
u"cache key %s" % url,
|
||||
u"real url %s" % url,
|
||||
u"info %s" % NNTP_INFO,
|
||||
u"warning No newsgroup specified in NNTP URL.",
|
||||
u"valid",
|
||||
]
|
||||
|
|
|
|||
Loading…
Reference in a new issue