~launchpad-pqm/launchpad/devel

« back to all changes in this revision

Viewing changes to lib/lp/soyuz/doc/gina.txt

  • Committer: Jeroen Vermeulen
  • Date: 2011-09-26 06:30:07 UTC
  • mto: This revision was merged to the branch mainline in revision 14049.
  • Revision ID: jeroen.vermeulen@canonical.com-20110926063007-1fb5eelnidpnra9a
Fix lots of lint in recently-changed files.

Show diffs side-by-side

added added

removed removed

Lines of Context:
110
110
And two completely broken packages:
111
111
 
112
112
   * util-linux, a source package that is missing from the pool. It
113
 
     generates 4 binary packages, all missing. It's correctly listed in Sources
114
 
     and Packages, though.
 
113
     generates 4 binary packages, all missing. It's correctly listed in
 
114
     Sources and Packages, though.
115
115
 
116
116
   * clearlooks, a source package with no binaries listed, and which has
117
117
     a DSC file that refers to an inexistant tar.gz.
186
186
    >>> transaction.commit()
187
187
    >>> fixture.cleanUp()
188
188
 
189
 
=== Testing Source Package Results ===
 
189
 
 
190
Testing Source Package Results
 
191
..............................
190
192
 
191
193
We should have more source packages in the database:
192
194
 
292
294
were calculated directly on the files):
293
295
 
294
296
    >>> from lp.soyuz.model.files import SourcePackageReleaseFile
295
 
    >>> files = SourcePackageReleaseFile.selectBy(sourcepackagereleaseID=cap.id,
296
 
    ...                                           orderBy="libraryfile")
 
297
    >>> files = SourcePackageReleaseFile.selectBy(
 
298
    ...     sourcepackagereleaseID=cap.id, orderBy="libraryfile")
297
299
    >>> for f in files:
298
300
    ...     print f.libraryfile.content.sha1
299
301
    107d5478e72385f714523bad5359efedb5dcc8b2
321
323
    >>> print db1.section.name
322
324
    libs
323
325
 
324
 
=== Testing Source Package Publishing ===
 
326
 
 
327
Testing Source Package Publishing
 
328
.................................
325
329
 
326
330
We check that the source package publishing override facility works:
327
331
 
337
341
successfully processed.
338
342
 
339
343
    - We had 2 errors (out of 10 Sources stanzas) in hoary: mkvmlinuz and
340
 
      util-linux
 
344
      util-linux.
341
345
 
342
 
    - We had 2 errors (out of 10 Sources stanzas) in breezy: python-sqllite and
343
 
      util-linux (again, poor thing)
 
346
    - We had 2 errors (out of 10 Sources stanzas) in breezy: python-sqllite
 
347
      and util-linux (again, poor thing).
344
348
 
345
349
    >>> print SSPPH.select().count() - orig_sspph_count
346
350
    21
347
351
 
348
 
    >>> print SSPPH.selectBy(
 
352
    >>> new_count = SSPPH.selectBy(
349
353
    ...     componentID=1,
350
 
    ...     pocket=PackagePublishingPocket.RELEASE).count() - \
351
 
    ...     orig_sspph_main_count
 
354
    ...     pocket=PackagePublishingPocket.RELEASE).count()
 
355
    >>> print new_count - orig_sspph_main_count
352
356
    21
353
357
 
354
 
=== Testing Binary Package Results ===
 
358
 
 
359
Testing Binary Package Results
 
360
..............................
355
361
 
356
362
We have 26 binary packages in hoary. The 4 packages for util-linux fail, and 1
357
363
package fails for each of python-sqlite and python-pam. We should publish one
358
364
entry for each package listed in Releases.
359
365
 
360
 
We have 23 binary packages in breezy. db1-compat, ed, the 3 libcap packages and
361
 
python-pam is unchanged.  python-sqlite fails. The 5 ubuntu-meta packages work.
 
366
We have 23 binary packages in breezy. db1-compat, ed, the 3 libcap packages
 
367
and python-pam is unchanged.  python-sqlite fails. The 5 ubuntu-meta packages
 
368
work.
362
369
 
363
370
    >>> BinaryPackageRelease.select().count() - orig_bpr_count
364
371
    40
456
463
XXX: test package with invalid source version
457
464
XXX: test package with maintainer with non-ascii name
458
465
 
459
 
=== Testing People Created ===
460
 
 
461
 
Ensure only one Kamion was created (he's an uploader on multiple packages), and
462
 
that we imported exactly 9 people (13 packages with 3 being uploaded by Kamion,
463
 
2 being uploaded by mdz and 2 by doko).
 
466
 
 
467
Testing People Created
 
468
......................
 
469
 
 
470
Ensure only one Kamion was created (he's an uploader on multiple packages),
 
471
and that we imported exactly 9 people (13 packages with 3 being uploaded by
 
472
Kamion, 2 being uploaded by mdz and 2 by doko).
464
473
 
465
474
    >>> from sqlobject import LIKE
466
475
    >>> p = Person.selectOne(LIKE(Person.q.name, u"cjwatson%"))
474
483
    13
475
484
 
476
485
 
477
 
=== Re-run Gina ===
 
486
Re-run Gina
 
487
...........
478
488
 
479
489
The second run of gina uses a test archive that is a copy of the first
480
490
one, but with updated Packages and Sources files for breezy that do
560
570
    >>> print SSPPH.select().count() - orig_sspph_count
561
571
    23
562
572
 
563
 
Check that the overrides we did were correctly issued. We can't use selectOneBy
564
 
because, of course, there may be multiple rows published for that package --
565
 
that's what overrides actually do.
 
573
Check that the overrides we did were correctly issued. We can't use
 
574
selectOneBy because, of course, there may be multiple rows published for that
 
575
package -- that's what overrides actually do.
566
576
 
567
577
    >>> from canonical.database.sqlbase import sqlvalues
568
578
    >>> x11_pub = SSPPH.select("""
597
607
    universe
598
608
 
599
609
 
600
 
=== Partner archive import ===
 
610
Partner archive import
 
611
......................
601
612
 
602
613
Importing the partner archive requires overriding the component to
603
614
"partner", which also makes the archive on any publishing records the
654
665
    set(['PARTNER'])
655
666
 
656
667
 
657
 
=== Source-only imports ===
 
668
Source-only imports
 
669
...................
658
670
 
659
671
Gina has a 'source-only' configuration option which allows it to
660
672
import only sources from the configured archive.
743
755
    True
744
756
 
745
757
 
746
 
=== Processing multiple suites in the same batch ===
 
758
Processing multiple suites in the same batch
 
759
............................................
747
760
 
748
761
Both, 'lenny' and 'hoary' (as partner) will be processed in the same
749
762
batch.
764
777
    0
765
778
 
766
779
 
767
 
=== Other tests ===
 
780
Other tests
 
781
...........
768
782
 
769
783
For kicks, finally, run gina on a configured but incomplete archive:
770
784
 
777
791
    >>> proc.wait()
778
792
    1
779
793
 
780
 
=== Wrap up ===
 
794
 
 
795
Wrap up
 
796
.......
781
797
 
782
798
Remove the tmp link to the gina_test_archive
783
799
    >>> os.remove('/tmp/gina_test_archive')