summaryrefslogtreecommitdiff
path: root/src/mailman/rules/docs
diff options
context:
space:
mode:
authorMark Sapiro2016-12-31 10:55:35 -0800
committerMark Sapiro2016-12-31 10:55:35 -0800
commit437c4b6388244636b128d96fa817202ba0c39e28 (patch)
tree0f7e98fe64a6aad2f5c693e8d6bc53d8d9b92d81 /src/mailman/rules/docs
parent5954094c36d1a0227ea21165f30085db4f424afe (diff)
downloadmailman-437c4b6388244636b128d96fa817202ba0c39e28.tar.gz
mailman-437c4b6388244636b128d96fa817202ba0c39e28.tar.zst
mailman-437c4b6388244636b128d96fa817202ba0c39e28.zip
Fixed location of 'with' in a test.
Removed unneeded 'as' clauses.
Diffstat (limited to 'src/mailman/rules/docs')
-rw-r--r--src/mailman/rules/docs/dmarc-mitigation.rst14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/mailman/rules/docs/dmarc-mitigation.rst b/src/mailman/rules/docs/dmarc-mitigation.rst
index 9a6fa5b9b..c16611a9c 100644
--- a/src/mailman/rules/docs/dmarc-mitigation.rst
+++ b/src/mailman/rules/docs/dmarc-mitigation.rst
@@ -37,7 +37,7 @@ A message From: a domain without a DMARC policy does not set any flags.
...
... """)
>>> msgdata = {}
- >>> with patcher as Resolver, patcher2 as urlopen:
+ >>> with patcher, patcher2:
... rule.check(mlist, msg, msgdata)
False
>>> msgdata == {}
@@ -54,7 +54,7 @@ action is no_mitigation.
...
... """)
>>> msgdata = {}
- >>> with patcher as Resolver, patcher2 as urlopen:
+ >>> with patcher, patcher2:
... rule.check(mlist, msg, msgdata)
False
>>> msgdata == {}
@@ -70,7 +70,7 @@ But with a different list setting, the message is flagged.
...
... """)
>>> msgdata = {}
- >>> with patcher as Resolver, patcher2 as urlopen:
+ >>> with patcher, patcher2:
... rule.check(mlist, msg, msgdata)
False
>>> msgdata['dmarc']
@@ -85,7 +85,7 @@ Subdomains which don't have a policy will check the organizational domain.
...
... """)
>>> msgdata = {}
- >>> with patcher as Resolver, patcher2 as urlopen:
+ >>> with patcher, patcher2:
... rule.check(mlist, msg, msgdata)
False
>>> msgdata['dmarc']
@@ -103,7 +103,7 @@ message.
...
... """)
>>> msgdata = {}
- >>> with patcher as Resolver, patcher2 as urlopen:
+ >>> with patcher, patcher2:
... rule.check(mlist, msg, msgdata)
True
>>> msgdata['dmarc']
@@ -122,7 +122,7 @@ We can reject the message with a default reason.
...
... """)
>>> msgdata = {}
- >>> with patcher as Resolver, patcher2 as urlopen:
+ >>> with patcher, patcher2:
... rule.check(mlist, msg, msgdata)
True
>>> msgdata['dmarc']
@@ -143,7 +143,7 @@ And, we can reject with a custom message.
...
... """)
>>> msgdata = {}
- >>> with patcher as Resolver, patcher2 as urlopen:
+ >>> with patcher, patcher2:
... rule.check(mlist, msg, msgdata)
True
>>> msgdata['dmarc']