Merge lp:~wgrant/launchpad/less-crackful-ddeb-tests into lp:launchpad

Proposed by William Grant
Status: Merged
Approved by: Aaron Bentley
Approved revision: not available
Merged at revision: not available
Proposed branch: lp:~wgrant/launchpad/less-crackful-ddeb-tests
Merge into: lp:launchpad
Diff against target: 206 lines (+43/-32)
4 files modified
lib/lp/archiveuploader/tests/data/suite/debug_1.0-1/debug_1.0-1.dsc (+5/-5)
lib/lp/archiveuploader/tests/data/suite/debug_1.0-1/debug_1.0-1_i386.changes (+10/-5)
lib/lp/archiveuploader/tests/data/suite/debug_1.0-1/debug_1.0-1_source.changes (+12/-6)
lib/lp/archiveuploader/tests/nascentupload-ddebs.txt (+16/-16)
To merge this branch: bzr merge lp:~wgrant/launchpad/less-crackful-ddeb-tests
Reviewer Review Type Date Requested Status
Aaron Bentley (community) Approve
Review via email: mp+16393@code.launchpad.net

Commit message

Rename the test suite's ddeb to match the naming scheme found on real packages.

To post a comment you must log in.
Revision history for this message
William Grant (wgrant) wrote :

In order to start handling DDEBs in Soyuz, we need to be able to link up DEBs with their corresponding DDEBs. We can only do this by matching on the name (in all real-world cases a DDEB's name is $DEBNAME-dbgsym).

Unfortunately, the binaries used in the test suite do not follow this mandatory standard. This branch renames the DDEB from debug-dbg to debug-bin-dbgsym, paving the way for my other DDEB support branches which would otherwise cause this upload to be rejected.

Revision history for this message
Aaron Bentley (abentley) wrote :

Looks good to me.

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== renamed directory 'lib/lp/archiveuploader/tests/data/suite/debug_1.0' => 'lib/lp/archiveuploader/tests/data/suite/debug_1.0-1'
=== added file 'lib/lp/archiveuploader/tests/data/suite/debug_1.0-1/debug-bin-dbgsym_1.0-1_i386.ddeb'
0Binary files lib/lp/archiveuploader/tests/data/suite/debug_1.0-1/debug-bin-dbgsym_1.0-1_i386.ddeb 1970-01-01 00:00:00 +0000 and lib/lp/archiveuploader/tests/data/suite/debug_1.0-1/debug-bin-dbgsym_1.0-1_i386.ddeb 2009-12-20 03:47:18 +0000 differ0Binary files lib/lp/archiveuploader/tests/data/suite/debug_1.0-1/debug-bin-dbgsym_1.0-1_i386.ddeb 1970-01-01 00:00:00 +0000 and lib/lp/archiveuploader/tests/data/suite/debug_1.0-1/debug-bin-dbgsym_1.0-1_i386.ddeb 2009-12-20 03:47:18 +0000 differ
=== renamed file 'lib/lp/archiveuploader/tests/data/suite/debug_1.0/debug-bin_1.0_i386.deb' => 'lib/lp/archiveuploader/tests/data/suite/debug_1.0-1/debug-bin_1.0-1_i386.deb'
1Binary files lib/lp/archiveuploader/tests/data/suite/debug_1.0/debug-bin_1.0_i386.deb 2009-04-15 13:45:42 +0000 and lib/lp/archiveuploader/tests/data/suite/debug_1.0-1/debug-bin_1.0-1_i386.deb 2009-12-20 03:47:18 +0000 differ1Binary files lib/lp/archiveuploader/tests/data/suite/debug_1.0/debug-bin_1.0_i386.deb 2009-04-15 13:45:42 +0000 and lib/lp/archiveuploader/tests/data/suite/debug_1.0-1/debug-bin_1.0-1_i386.deb 2009-12-20 03:47:18 +0000 differ
=== renamed file 'lib/lp/archiveuploader/tests/data/suite/debug_1.0/debug_1.0.dsc' => 'lib/lp/archiveuploader/tests/data/suite/debug_1.0-1/debug_1.0-1.dsc'
--- lib/lp/archiveuploader/tests/data/suite/debug_1.0/debug_1.0.dsc 2009-04-15 13:45:42 +0000
+++ lib/lp/archiveuploader/tests/data/suite/debug_1.0-1/debug_1.0-1.dsc 2009-12-20 03:47:18 +0000
@@ -1,13 +1,13 @@
1Format: 1.01Format: 1.0
2Source: debug2Source: debug
3Binary: debug-bin, debug-dbg3Binary: debug-bin, debug-bin-dbgsym
4Architecture: any4Architecture: any
5Version: 1.05Version: 1.0-1
6Maintainer: Launchpad team <launchpad@lists.canonical.com>6Maintainer: Launchpad team <launchpad@lists.canonical.com>
7Standards-Version: 3.6.27Standards-Version: 3.6.2
8Checksums-Sha1: 8Checksums-Sha1:
9 f1b127517fca94cd06444d452ce32a68fbe24c93 744 debug_1.0.tar.gz9 6851f625a32f6c83a1af4c972b5bead14fbee06c 740 debug_1.0-1.tar.gz
10Checksums-Sha256: 10Checksums-Sha256:
11 95537a19d65855ea42695589d8f876e6d4390c906583de7cd4a16842b303d440 744 debug_1.0.tar.gz11 1a1ed198644169f16eeee93c843ab8b7d9eef25cd91b83f55f497dbe744d3c95 740 debug_1.0-1.tar.gz
12Files: 12Files:
13 499069ad47e21b7dde887b46eada8972 744 debug_1.0.tar.gz13 8225b515f30dd8c0252847f17f4b7069 740 debug_1.0-1.tar.gz
1414
=== renamed file 'lib/lp/archiveuploader/tests/data/suite/debug_1.0/debug_1.0.tar.gz' => 'lib/lp/archiveuploader/tests/data/suite/debug_1.0-1/debug_1.0-1.tar.gz'
15Binary files lib/lp/archiveuploader/tests/data/suite/debug_1.0/debug_1.0.tar.gz 2009-04-15 13:45:42 +0000 and lib/lp/archiveuploader/tests/data/suite/debug_1.0-1/debug_1.0-1.tar.gz 2009-12-20 03:47:18 +0000 differ15Binary files lib/lp/archiveuploader/tests/data/suite/debug_1.0/debug_1.0.tar.gz 2009-04-15 13:45:42 +0000 and lib/lp/archiveuploader/tests/data/suite/debug_1.0-1/debug_1.0-1.tar.gz 2009-12-20 03:47:18 +0000 differ
=== renamed file 'lib/lp/archiveuploader/tests/data/suite/debug_1.0/debug_1.0_i386.changes' => 'lib/lp/archiveuploader/tests/data/suite/debug_1.0-1/debug_1.0-1_i386.changes'
--- lib/lp/archiveuploader/tests/data/suite/debug_1.0/debug_1.0_i386.changes 2009-05-11 20:55:01 +0000
+++ lib/lp/archiveuploader/tests/data/suite/debug_1.0-1/debug_1.0-1_i386.changes 2009-12-20 03:47:18 +0000
@@ -3,7 +3,7 @@
3Source: debug3Source: debug
4Binary: debug-bin4Binary: debug-bin
5Architecture: i3865Architecture: i386
6Version: 1.06Version: 1.0-1
7Distribution: hoary7Distribution: hoary
8Urgency: low8Urgency: low
9Maintainer: Launchpad team <launchpad@lists.canonical.com>9Maintainer: Launchpad team <launchpad@lists.canonical.com>
@@ -11,10 +11,15 @@
11Description: 11Description:
12 debug-bin - Stuff for testing12 debug-bin - Stuff for testing
13Changes: 13Changes:
14 debug (1.0) hoary; urgency=low14 debug (1.0-1) hoary; urgency=low
15 .15 .
16 * Testing debug binaries16 * Testing debug binaries
17Checksums-Sha1:
18 91556113ad38eb35d2fe03d27ae646e0ed487a3d 654 debug-bin_1.0-1_i386.deb
19 d120be63a4535e31ec08657cc4d3018cc8b62d54 668 debug-bin-dbgsym_1.0-1_i386.ddeb
20Checksums-Sha256:
21 5ca0ce3d3bfde3cc698d9ad4b027663abecb958bea641d29ac3bf8333fd3ebad 654 debug-bin_1.0-1_i386.deb
22 9c0013badb1bb78fa1ccbf1508398cbf51904f7242d8931f4994c1aa18519b63 668 debug-bin-dbgsym_1.0-1_i386.ddeb
17Files: 23Files:
18 88eae94b28fcffdbfaeb520549f81d1d 654 devel optional debug-bin_1.0_i386.deb24 48b4eed5980c754cc74a06ffc4372f64 654 devel optional debug-bin_1.0-1_i386.deb
19 0ab4cf3b1b0422192c41060d903c3f51 664 devel optional debug-dbg_1.0_i386.ddeb25 ac5c44025ffc026485b22722e0f13804 668 devel optional debug-bin-dbgsym_1.0-1_i386.ddeb
20
2126
=== renamed file 'lib/lp/archiveuploader/tests/data/suite/debug_1.0/debug_1.0_source.changes' => 'lib/lp/archiveuploader/tests/data/suite/debug_1.0-1/debug_1.0-1_source.changes'
--- lib/lp/archiveuploader/tests/data/suite/debug_1.0/debug_1.0_source.changes 2009-04-15 13:45:42 +0000
+++ lib/lp/archiveuploader/tests/data/suite/debug_1.0-1/debug_1.0-1_source.changes 2009-12-20 03:47:18 +0000
@@ -1,20 +1,26 @@
1Format: 1.81Format: 1.8
2Date: Thu, 15 Apr 2009 15:14:09 +01002Date: Thu, 15 Apr 2009 15:14:09 +0100
3Source: debug3Source: debug
4Binary: debug-bin debug-dbg4Binary: debug-bin debug-bin-dbgsym
5Architecture: source5Architecture: source
6Version: 1.06Version: 1.0-1
7Distribution: hoary7Distribution: hoary
8Urgency: low8Urgency: low
9Maintainer: Launchpad team <launchpad@lists.canonical.com>9Maintainer: Launchpad team <launchpad@lists.canonical.com>
10Changed-By: Celso Providelo <cprov@canonical.com>10Changed-By: Celso Providelo <cprov@canonical.com>
11Description: 11Description:
12 debug-bin - Stuff for testing12 debug-bin - Stuff for testing
13 debug-dbg - Stuff for testing DDEBs13 debug-bin-dbgsym - Stuff for testing DDEBs
14Changes: 14Changes:
15 debug (1.0) hoary; urgency=low15 debug (1.0-1) hoary; urgency=low
16 .16 .
17 * Testing debug binaries17 * Testing debug binaries
18Checksums-Sha1:
19 f30c2462e897e07534a5c9960a8f653d5a51b066 434 debug_1.0-1.dsc
20 6851f625a32f6c83a1af4c972b5bead14fbee06c 740 debug_1.0-1.tar.gz
21Checksums-Sha256:
22 ab5e1eea2551828761d8734224d1a024be401ac05e83010494a0d9c69b8982c3 434 debug_1.0-1.dsc
23 1a1ed198644169f16eeee93c843ab8b7d9eef25cd91b83f55f497dbe744d3c95 740 debug_1.0-1.tar.gz
18Files: 24Files:
19 f9361791f0d81a607f6b4ce911fdbb0d 419 devel optional debug_1.0.dsc25 81d19cae151472dfd2f797a69a2c1f54 434 devel optional debug_1.0-1.dsc
20 499069ad47e21b7dde887b46eada8972 744 devel optional debug_1.0.tar.gz26 8225b515f30dd8c0252847f17f4b7069 740 devel optional debug_1.0-1.tar.gz
2127
=== removed file 'lib/lp/archiveuploader/tests/data/suite/debug_1.0/debug-dbg_1.0_i386.ddeb'
22Binary files lib/lp/archiveuploader/tests/data/suite/debug_1.0/debug-dbg_1.0_i386.ddeb 2009-04-15 13:45:42 +0000 and lib/lp/archiveuploader/tests/data/suite/debug_1.0/debug-dbg_1.0_i386.ddeb 1970-01-01 00:00:00 +0000 differ28Binary files lib/lp/archiveuploader/tests/data/suite/debug_1.0/debug-dbg_1.0_i386.ddeb 2009-04-15 13:45:42 +0000 and lib/lp/archiveuploader/tests/data/suite/debug_1.0/debug-dbg_1.0_i386.ddeb 1970-01-01 00:00:00 +0000 differ
=== modified file 'lib/lp/archiveuploader/tests/nascentupload-ddebs.txt'
--- lib/lp/archiveuploader/tests/nascentupload-ddebs.txt 2009-05-06 20:53:05 +0000
+++ lib/lp/archiveuploader/tests/nascentupload-ddebs.txt 2009-12-20 03:47:18 +0000
@@ -11,8 +11,8 @@
1111
12First we will create a source and a corresponding binary publication12First we will create a source and a corresponding binary publication
13in the database, 'debug' and 'debug-bin' version '0.9', which will be13in the database, 'debug' and 'debug-bin' version '0.9', which will be
14an ancestor for the subsequent upload containing a 'debug-dbg' DDEB.14an ancestor for the subsequent upload containing a 'debug-bin-dbgsym'
15This is done using `SoyuzTestPublisher`.15DDEB. This is done using `SoyuzTestPublisher`.
1616
17 >>> from lp.soyuz.tests.test_publishing import (17 >>> from lp.soyuz.tests.test_publishing import (
18 ... SoyuzTestPublisher)18 ... SoyuzTestPublisher)
@@ -43,28 +43,28 @@
43 >>> LaunchpadZopelessLayer.txn.commit()43 >>> LaunchpadZopelessLayer.txn.commit()
44 >>> LaunchpadZopelessLayer.switchDbUser('uploader')44 >>> LaunchpadZopelessLayer.switchDbUser('uploader')
4545
46With that done, we now upload a new source, 'debug - 1.0', which is46With that done, we now upload a new source, 'debug - 1.0-1', which is
47immediately accepted and stands pending publication.47immediately accepted and stands pending publication.
4848
49 >>> src = getUploadForSource(49 >>> src = getUploadForSource(
50 ... 'suite/debug_1.0/debug_1.0_source.changes')50 ... 'suite/debug_1.0-1/debug_1.0-1_source.changes')
51 >>> src.process()51 >>> src.process()
52 >>> result = src.do_accept()52 >>> result = src.do_accept()
53 >>> print src.queue_root.status.name53 >>> print src.queue_root.status.name
54 DONE54 DONE
5555
56 >>> [src_pub] = src.queue_root.archive.getPublishedSources(56 >>> [src_pub] = src.queue_root.archive.getPublishedSources(
57 ... name='debug', version='1.0', exact_match=True)57 ... name='debug', version='1.0-1', exact_match=True)
5858
59 >>> print src_pub.displayname, src_pub.status.name59 >>> print src_pub.displayname, src_pub.status.name
60 debug 1.0 in hoary PENDING60 debug 1.0-1 in hoary PENDING
6161
62At this point a deb and a ddeb, produced during a normal build62At this point a deb and a ddeb, produced during a normal build
63process, are uploaded. This is exactly the same procedure used for63process, are uploaded. This is exactly the same procedure used for
64binary uploads with only ordinary debs.64binary uploads with only ordinary debs.
6565
66 >>> bin = getUploadForBinary(66 >>> bin = getUploadForBinary(
67 ... 'suite/debug_1.0/debug_1.0_i386.changes')67 ... 'suite/debug_1.0-1/debug_1.0-1_i386.changes')
6868
69DDEBs undergo exactly the same checks as ordinary DEBs. These are69DDEBs undergo exactly the same checks as ordinary DEBs. These are
70never considered NEW, so the binary upload has a 'never-seen-before'70never considered NEW, so the binary upload has a 'never-seen-before'
@@ -91,8 +91,8 @@
91 ... print '%s %s %s' % (91 ... print '%s %s %s' % (
92 ... bin_pub.displayname, bin_pub.status.name,92 ... bin_pub.displayname, bin_pub.status.name,
93 ... bin_pub.archive.purpose.name)93 ... bin_pub.archive.purpose.name)
94 debug-bin 1.0 in hoary i386 PENDING PRIMARY94 debug-bin 1.0-1 in hoary i386 PENDING PRIMARY
95 debug-dbg 1.0 in hoary i386 PENDING DEBUG95 debug-bin-dbgsym 1.0-1 in hoary i386 PENDING DEBUG
9696
97DEBs and DDEBs are uploaded to separate archives, because the size97DEBs and DDEBs are uploaded to separate archives, because the size
98impact of uploading them to a single archive on mirrors would be98impact of uploading them to a single archive on mirrors would be
@@ -104,7 +104,7 @@
104 >>> ddeb = ddeb_pub.binarypackagerelease104 >>> ddeb = ddeb_pub.binarypackagerelease
105105
106 >>> print ddeb.title106 >>> print ddeb.title
107 debug-dbg-1.0107 debug-bin-dbgsym-1.0-1
108108
109The corresponding `BinaryPackageRelease` is recorded with DDEB format.109The corresponding `BinaryPackageRelease` is recorded with DDEB format.
110110
@@ -115,7 +115,7 @@
115115
116 >>> for bin_file in ddeb.files:116 >>> for bin_file in ddeb.files:
117 ... print bin_file.libraryfile.filename, bin_file.filetype.name117 ... print bin_file.libraryfile.filename, bin_file.filetype.name
118 debug-dbg_1.0_i386.ddeb DDEB118 debug-bin-dbgsym_1.0-1_i386.ddeb DDEB
119119
120120
121== DDEBs in other archives ==121== DDEBs in other archives ==
@@ -144,15 +144,15 @@
144 ... binaryname='debug-bin', pub_source=copied_source, archive=copy)144 ... binaryname='debug-bin', pub_source=copied_source, archive=copy)
145145
146 >>> src_pub = test_publisher.getPubSource(146 >>> src_pub = test_publisher.getPubSource(
147 ... sourcename='debug', version='1.0', archive=copy)147 ... sourcename='debug', version='1.0-1', archive=copy)
148148
149 >>> print src_pub.displayname, src_pub.status.name149 >>> print src_pub.displayname, src_pub.status.name
150 debug 1.0 in hoary PENDING150 debug 1.0-1 in hoary PENDING
151151
152Now we upload the DEB and the DDEB, which are auto-accepted.152Now we upload the DEB and the DDEB, which are auto-accepted.
153153
154 >>> bin = getUploadForBinary(154 >>> bin = getUploadForBinary(
155 ... 'suite/debug_1.0/debug_1.0_i386.changes')155 ... 'suite/debug_1.0-1/debug_1.0-1_i386.changes')
156 >>> bin.policy.archive = copy156 >>> bin.policy.archive = copy
157157
158 >>> bin.process()158 >>> bin.process()
@@ -175,6 +175,6 @@
175 ... print '%s %s %s' % (175 ... print '%s %s %s' % (
176 ... bin_pub.displayname, bin_pub.status.name,176 ... bin_pub.displayname, bin_pub.status.name,
177 ... bin_pub.archive.purpose.name)177 ... bin_pub.archive.purpose.name)
178 debug-bin 1.0 in hoary i386 PENDING COPY178 debug-bin 1.0-1 in hoary i386 PENDING COPY
179 debug-dbg 1.0 in hoary i386 PENDING COPY179 debug-bin-dbgsym 1.0-1 in hoary i386 PENDING COPY
180180