~launchpad-pqm/launchpad/devel

« back to all changes in this revision

Viewing changes to lib/lp/code/tests/helpers.py

  • 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:
13
13
    'make_official_package_branch',
14
14
    'make_project_branch_with_revisions',
15
15
    'make_project_cloud_data',
16
 
    'remove_all_sample_data_branches',
17
16
    ]
18
17
 
19
18
 
40
39
    )
41
40
from lp.registry.interfaces.pocket import PackagePublishingPocket
42
41
from lp.registry.interfaces.series import SeriesStatus
43
 
from lp.services.database.sqlbase import cursor
44
42
from lp.testing import (
45
43
    run_with_login,
46
44
    time_counter,
329
327
    return '~%s/%s/%s/%s/%s' % (
330
328
        owner, distroseries.distribution.name, distroseries.name,
331
329
        source_package, branch)
332
 
 
333
 
 
334
 
def remove_all_sample_data_branches():
335
 
    c = cursor()
336
 
    c.execute('delete from bugbranch')
337
 
    c.execute('delete from specificationbranch')
338
 
    c.execute('update productseries set branch=NULL')
339
 
    c.execute('delete from branchrevision')
340
 
    c.execute('delete from branchsubscription')
341
 
    c.execute('delete from codeimportjob')
342
 
    c.execute('delete from codeimport')
343
 
    c.execute('delete from branch')