Merge lp://staging/~gary/launchpad/bug723999-2a into lp://staging/launchpad

Proposed by Gary Poster
Status: Merged
Merged at revision: 12548
Proposed branch: lp://staging/~gary/launchpad/bug723999-2a
Merge into: lp://staging/launchpad
Diff against target: 472 lines (+106/-99)
3 files modified
lib/lp/bugs/interfaces/structuralsubscription.py (+0/-8)
lib/lp/bugs/model/structuralsubscription.py (+39/-27)
lib/lp/bugs/tests/test_structuralsubscriptiontarget.py (+67/-64)
To merge this branch: bzr merge lp://staging/~gary/launchpad/bug723999-2a
Reviewer Review Type Date Requested Status
Benji York (community) code Approve
Review via email: mp+52427@code.staging.launchpad.net

Description of the change

This MP is one of several I'll be making to clean up my work on bug723999. I'm dividing up the work to try and make it easier to review.

This branch is about removing the getSubscriptionsForBugTask method on bug targets. It only had existed after my previous work on bug723999 because of tests that I didn't change because of branch size issues earlier.

I replace it with the get_structural_subscribers function. The get_structural_subscribers_for_bugtasks function remains as a wrapper for get_structural_subscribers (again, because of branch review size limitations); it will disappear in subsequent branches, leaving only get_structural_subscribers. As you can tell from the wrapper function, we only use this functionality in LP by either passing a list of a single bugtask, or all of the bugtasks in a bug. I'll be changing the rest of LP to explicitly do that in a future branch.

I adapted the tests to use the new function. Unfortunately, they are in the wrong module, because this code no longer has anything to do with targets directly. I will move the tests to test_structuralsubscription.py in a subsequent branch.

make lint is happy.

Thank you

Gary

To post a comment you must log in.
Revision history for this message
Benji York (benji) wrote :

This branch looks fine, being primarily a mechanical transformation from one perspective to another.

review: Approve (code)

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.