Merge lp://staging/~brian-murray/launchpad/x-launchpad-bug-modifier-follow-on into lp://staging/launchpad

Proposed by Brian Murray
Status: Merged
Approved by: Māris Fogels
Approved revision: no longer in the source branch.
Merged at revision: 11379
Proposed branch: lp://staging/~brian-murray/launchpad/x-launchpad-bug-modifier-follow-on
Merge into: lp://staging/launchpad
Diff against target: 77 lines (+61/-1)
2 files modified
lib/lp/bugs/mail/tests/test_bug_task_modification.py (+60/-0)
lib/lp/bugs/scripts/bugnotification.py (+1/-1)
To merge this branch: bzr merge lp://staging/~brian-murray/launchpad/x-launchpad-bug-modifier-follow-on
Reviewer Review Type Date Requested Status
Māris Fogels (community) Approve
Review via email: mp+32900@code.staging.launchpad.net

Commit message

Add in X-Launchpad-Bug-Modifier header, identifying the event creator's display name and name, to bug mail generated by bugnotification.py.

Description of the change

This branch is a follows up a merge proposal, https://code.edge.launchpad.net/~brian-murray/launchpad/bug-605340/+merge/31221, to add an X-Launchpad-Bug-Modifier header to emails sent regarding bug changes. That branch was supposed to fix bug 605340, however it does this incompletely by only adding the header when bug details are sent to new subscribers. This branch adds person to BugNotificationBuilder call in lp/bugs/scripts/bugnotification.py so that all bug mails will have the X-Launchpad-Bug-Modifier header.

I also added in a test, test_bug_task_modification.py, to confirm that the header appears when a bug's status is changed.

== Tests ==

bin/test -cvv -t bugnotification-email -t test_bug_task_modification

To post a comment you must log in.
Revision history for this message
Māris Fogels (mars) wrote :

Hi Brian,

These changes look good. I just had a few questions:

 * On line 28 of the diff, there are brackets around ObjectModifiedEvent. I assume that is a left-over from earlier imports?
 * The docstring for TestModificationNotification should either be made more general, or the class name should be made more specific to match the docstring.
 * Is the sanity check for the stub mailer on line 50 of the diff necessary? I would hope the TestCase object reliably cleans up the stub mailer for you.

I think the branch looks good. r=mars with the tweaks I listed above.

Maris

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
The diff is not available at this time. You can reload the page or download it.