~launchpad-pqm/launchpad/devel

« back to all changes in this revision

Viewing changes to lib/lp/soyuz/doc/soyuz-upload.txt

Merge databasefixture.

Show diffs side-by-side

added added

removed removed

Lines of Context:
68
68
the poppy server. We send each package set on a different ftp
69
69
session.
70
70
 
 
71
  >>> from canonical.config import config
71
72
  >>> from lp.archiveuploader.tagfiles import parse_tagfile
72
 
  >>> from canonical.config import config
73
73
  >>> import glob
74
74
  >>> test_files_dir = os.path.join(config.root,
75
75
  ...                               "lib/lp/soyuz/scripts/"
212
212
 
213
213
So, load the GPG key:
214
214
 
 
215
  >>> from zope.component import getUtility
215
216
  >>> from canonical.launchpad.ftests.keys_for_tests import gpgkeysdir
216
217
  >>> from canonical.launchpad.interfaces.gpghandler import IGPGHandler
217
 
  >>> from zope.component import getUtility
218
218
  >>> gpg_handler = getUtility(IGPGHandler)
219
219
  >>> key_path = os.path.join(gpgkeysdir, 'ftpmaster@canonical.com.pub')
220
220
  >>> key_data = open(key_path).read()
227
227
Create the katie user and register it in a team that is allowed to
228
228
do uploads:
229
229
 
230
 
  >>> from canonical.launchpad.interfaces import (
231
 
  ...     IPersonSet, IEmailAddressSet, PersonCreationRationale, IGPGKeySet,
232
 
  ...     GPGKeyAlgorithm)
 
230
  >>> from canonical.launchpad.interfaces.emailaddress import IEmailAddressSet
 
231
  >>> from lp.registry.interfaces.gpg import (
 
232
  ...     GPGKeyAlgorithm,
 
233
  ...     IGPGKeySet,
 
234
  ...     )
 
235
  >>> from lp.registry.interfaces.person import (
 
236
  ...     IPersonSet,
 
237
  ...     PersonCreationRationale,
 
238
  ...     )
233
239
  >>> name, address = "Katie", "katie@rockhopper.ubuntu.com"
234
240
  >>> user = getUtility(IPersonSet).ensurePerson(
235
241
  ...     address, name, PersonCreationRationale.OWNER_CREATED_LAUNCHPAD)
529
535
 
530
536
These packages must now be in the publishing history. Let's check it.
531
537
 
532
 
  >>> from canonical.launchpad.database import (
 
538
  >>> from lp.soyuz.model.publishing import (
533
539
  ...    SourcePackagePublishingHistory as SSPPH)
534
540
  >>> package_names.sort()
535
541
  >>> for name in package_names: