~launchpad-pqm/launchpad/devel

« back to all changes in this revision

Viewing changes to lib/lp/code/doc/branch.txt

  • Committer: Curtis Hovey
  • Date: 2011-12-18 15:13:07 UTC
  • mto: This revision was merged to the branch mainline in revision 14547.
  • Revision ID: curtis.hovey@canonical.com-20111218151307-sdm2gzobt5tplbe0
Moved badges to lp.app.

Show diffs side-by-side

added added

removed removed

Lines of Context:
27
27
Interfaces
28
28
----------
29
29
 
30
 
    >>> from lp.services.webapp.testing import verifyObject
 
30
    >>> from canonical.launchpad.webapp.testing import verifyObject
31
31
    >>> from lp.code.enums import BranchType
32
32
    >>> from lp.code.interfaces.branch import IBranchSet
33
33
    >>> from lp.code.interfaces.branchsubscription import IBranchSubscription
172
172
up our tests, so we clear the last_scanned data in all existing
173
173
branches.
174
174
 
175
 
    >>> from lp.services.webapp.interfaces import (
 
175
    >>> from canonical.launchpad.webapp.interfaces import (
176
176
    ...     IStoreSelector, MAIN_STORE, DEFAULT_FLAVOR)
177
177
    >>> store = getUtility(IStoreSelector).get(MAIN_STORE, DEFAULT_FLAVOR)
178
178
    >>> store.find(Branch).set(last_scanned=None)
312
312
    >>> set(branch.subscribers) == set([branch.owner, subscriber])
313
313
    True
314
314
 
315
 
    >>> from lp.services.webapp import canonical_url
 
315
    >>> from canonical.launchpad.webapp import canonical_url
316
316
    >>> print canonical_url(subscription)
317
317
    http://code...dev/~user/product/subscribed/+subscription/subscriber
318
318
 
377
377
 
378
378
The current references to the branch table are shown here.
379
379
 
380
 
    >>> from lp.services.database import postgresql
381
 
    >>> from lp.services.database.sqlbase import cursor
 
380
    >>> from canonical.database import postgresql
 
381
    >>> from canonical.database.sqlbase import cursor
382
382
    >>> cur = cursor()
383
383
    >>> references = list(postgresql.listReferences(cur, 'branch', 'id'))
384
384