launchpad-reviewers team mailing list archive
-
launchpad-reviewers team
-
Mailing list archive
-
Message #27321
[Merge] ~cjwatson/launchpad:flake8-fix-processBadVote into launchpad:master
Colin Watson has proposed merging ~cjwatson/launchpad:flake8-fix-processBadVote into launchpad:master.
Commit message:
Fix bad flake8 correction in TestCodeHandler.test_processBadVote
Requested reviews:
Launchpad code reviewers (launchpad-reviewers)
For more details, see:
https://code.launchpad.net/~cjwatson/launchpad/+git/launchpad/+merge/406396
--
Your team Launchpad code reviewers is requested to review the proposed merge of ~cjwatson/launchpad:flake8-fix-processBadVote into launchpad:master.
diff --git a/lib/lp/code/mail/tests/test_codehandler.py b/lib/lp/code/mail/tests/test_codehandler.py
index 55fd4a5..d826925 100644
--- a/lib/lp/code/mail/tests/test_codehandler.py
+++ b/lib/lp/code/mail/tests/test_codehandler.py
@@ -219,7 +219,7 @@ class TestCodeHandler(TestCaseWithFactory):
# The returned message is a multipart message, the first part is
# the message, and the second is the original message.
message, original = notification.get_payload()
- self.assertEqual(dedent("""\
+ expected_payload = dedent("""\
An error occurred while processing a mail you sent to Launchpad's email
interface.
@@ -229,8 +229,7 @@ class TestCodeHandler(TestCaseWithFactory):
Error message:
The 'review' command expects any of the following arguments:
- abstain, approve, disapprove, needs-fixing, needs-info,
- needs-resubmitting
+ abstain, approve, disapprove, needs-fixing, needs-info, needs-resubmitting
For example:
@@ -240,8 +239,9 @@ class TestCodeHandler(TestCaseWithFactory):
--\x20
For more information about using Launchpad by email, see
https://help.launchpad.net/EmailInterface
- or send an email to help@xxxxxxxxxxxxx""").encode("UTF-8"),
- message.get_payload(decode=True))
+ or send an email to help@xxxxxxxxxxxxx""") # noqa: E501
+ self.assertEqual(
+ expected_payload.encode("UTF-8"), message.get_payload(decode=True))
self.assertEqual(mail['From'], notification['To'])
def test_getReplyAddress(self):