Kaydet (Commit) 14d99a14 authored tarafından Nick Coghlan's avatar Nick Coghlan

Ignore X-Antivirus headers in test_nntplib

üst e6ef4622
...@@ -176,7 +176,10 @@ class NetworkedNNTPTestsMixin: ...@@ -176,7 +176,10 @@ class NetworkedNNTPTestsMixin:
resp, article = self.server.article(art_num) resp, article = self.server.article(art_num)
self.assertTrue(resp.startswith("220 "), resp) self.assertTrue(resp.startswith("220 "), resp)
self.check_article_resp(resp, article, art_num) self.check_article_resp(resp, article, art_num)
self.assertEqual(article.lines, head.lines + [b''] + body.lines) # Tolerate running the tests from behind a NNTP virus checker
filtered_lines = [line for line in article.lines
if not line.startswith(b'X-Antivirus')]
self.assertEqual(filtered_lines, head.lines + [b''] + body.lines)
def test_capabilities(self): def test_capabilities(self):
# The server under test implements NNTP version 2 and has a # The server under test implements NNTP version 2 and has a
......
...@@ -301,6 +301,9 @@ Extension Modules ...@@ -301,6 +301,9 @@ Extension Modules
Tests Tests
----- -----
- test_nntplib now tolerates being run from behind NNTP gateways that add
"X-Antivirus" headers to articles
- Issue #15043: test_gdb is now skipped entirely if gdb security settings - Issue #15043: test_gdb is now skipped entirely if gdb security settings
block loading of the gdb hooks block loading of the gdb hooks
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment