Merge lp:~michael.nelson/launchpad/ppa-privatisation-test-refactor into lp:launchpad
| Status: | Merged | ||||
|---|---|---|---|---|---|
| Approved by: | Edwin Grubbs on 2010-02-17 | ||||
| Approved revision: | not available | ||||
| Merged at revision: | not available | ||||
| Proposed branch: | lp:~michael.nelson/launchpad/ppa-privatisation-test-refactor | ||||
| Merge into: | lp:launchpad | ||||
| Prerequisite: | lp:~michael.nelson/launchpad/506203-ppa-privatisation-check | ||||
| Diff against target: |
586 lines (+143/-152) 3 files modified
lib/lp/archivepublisher/tests/publisher-config.txt (+9/-11) lib/lp/soyuz/doc/archive.txt (+120/-128) lib/lp/soyuz/doc/buildd-scoring.txt (+14/-13) |
||||
| To merge this branch: | bzr merge lp:~michael.nelson/launchpad/ppa-privatisation-test-refactor | ||||
| Related bugs: |
|
| Reviewer | Review Type | Date Requested | Status |
|---|---|---|---|
| Edwin Grubbs (community) | code | 2010-02-17 | Approve on 2010-02-17 |
|
Review via email:
|
|||
| Michael Nelson (michael.nelson) wrote : | # |
| Edwin Grubbs (edwin-grubbs) wrote : | # |
Hi Michael,
This is a nice improvement. Minor comments below.
merge-conditional
-Edwin
>=== modified file 'lib/lp/
>--- lib/lp/
>+++ lib/lp/
>@@ -102,10 +102,15 @@
> essentially the password to the archive for the builder.
>
> It can only be set by users with launchpad.
>-archive, i.e. an admin or a commercial admin.
>+archive, i.e. an admin or a commercial admin. We create a new PPA for
>+cprov here as changing privacy of a PPA is not allowed when sources have
>+already been published.
>
>+ >>> cprov_private_ppa = factory.
>+ ... owner=cprov, name='myprivate
>+ ... distribution=
Replace tab with spaces.
> >>> login(ANONYMOUS)
>- >>> cprov_archive.
>+ >>> cprov_private_
>
> Traceback (most recent call last):
> ...
> Unauthorized: (..., 'buildd_secret', 'launchpad.
>@@ -1755,18 +1750,20 @@
> pmount 0.1-1 in warty PUBLISHED cprov
>
> Private source publications are excluded from this list, the fact that
>-they exist should never leak. If we make Celso's PPA private, its
>-contents will not be listed anymore. The same happens for uploaded
>-sources, since they are essentially another source publication in this
>-context.
>+they exist should never leak. If we copy the package to Celso's private
>+PPA the list is not updated. The same happens for uploaded sources, since they
Line too long.
>+are essentially another source publication in this context.
>
>- >>> naked_cprov_
>- >>> naked_cprov_
>+ >>> copy = cprov_cdrkit.
>+ ... ubuntu['hoary'], PackagePublishi
>+ ... cprov_private_ppa)
Replace tab with spaces.
> >>> print_latest_
> cdrkit 1.0 in hoary PENDING mark
> iceweasel 1.0 in hoary PENDING mark
>+ cdrkit 1.0 in breezy-autotest SUPERSEDED cprov
> iceweasel 1.0 in breezy-autotest PUBLISHED mark
>+ pmount 0.1-1 in warty PUBLISHED cprov
>
> 'getMostActiveP
> containing up to 5 PPAs with the highest number of publications in the
>@@ -1808,14 +1805,13 @@
> ... a_pub.copyTo(
> ... ubuntu['hoary'], PackagePublishi
>
>- >>> create_
>+ >>> create_
> >>> create_
> >>> create_
> >>> create_
> >>> create_
>
>-Celso's PPA is still private, so despite having the highest number of
>-uploads it's not listed.
>+Celso's private PPA is not listed despite having the highest number of uploads.
Line too long.
> >>> print_most_
> PPA for Foo Bar 10
>@@ -1824,13 +1820,11 @@
> PPA for Sample Person 4
> PPA for Mark Shuttleworth 2
>
>-When we make Celso's PPA public the result gets limited to 5 items.
>-The p...
| Michael Nelson (michael.nelson) wrote : | # |
On Wed, Feb 17, 2010 at 6:39 PM, Edwin Grubbs
<email address hidden> wrote:
> Review: Approve code
> Hi Michael,
>
> This is a nice improvement. Minor comments below.
>
> merge-conditional
>
> -Edwin
Hi Edwin, it looks like you actually went through some of the
prerequisite branch changes too... thanks!
>
>
>>=== modified file 'lib/lp/
>>--- lib/lp/
>>+++ lib/lp/
>>@@ -102,10 +102,15 @@
>> essentially the password to the archive for the builder.
>>
>> It can only be set by users with launchpad.
>>-archive, i.e. an admin or a commercial admin.
>>+archive, i.e. an admin or a commercial admin. We create a new PPA for
>>+cprov here as changing privacy of a PPA is not allowed when sources have
>>+already been published.
>>
>>+ >>> cprov_private_ppa = factory.
>>+ ... owner=cprov, name='myprivate
>>+ ... distribution=
>
>
> Replace tab with spaces.
Sorry - switched editors recently, I've updated to automatically expand now.
>
>
>> >>> login(ANONYMOUS)
>>- >>> cprov_archive.
>>+ >>> cprov_private_
>>
>> Traceback (most recent call last):
>> ...
>> Unauthorized: (..., 'buildd_secret', 'launchpad.
>>@@ -1755,18 +1750,20 @@
>> pmount 0.1-1 in warty PUBLISHED cprov
>>
>> Private source publications are excluded from this list, the fact that
>>-they exist should never leak. If we make Celso's PPA private, its
>>-contents will not be listed anymore. The same happens for uploaded
>>-sources, since they are essentially another source publication in this
>>-context.
>>+they exist should never leak. If we copy the package to Celso's private
>>+PPA the list is not updated. The same happens for uploaded sources, since they
>
>
> Line too long.
... and to highlight from 78 rather than 79.
>
>
>>+are essentially another source publication in this context.
>>
>>- >>> naked_cprov_
>>- >>> naked_cprov_
>>+ >>> copy = cprov_cdrkit.
>>+ ... ubuntu['hoary'], PackagePublishi
>>+ ... cprov_private_ppa)
>
>
> Replace tab with spaces.
Done
>
>
>> >>> print_latest_
>> cdrkit 1.0 in hoary PENDING mark
>> iceweasel 1.0 in hoary PENDING mark
>>+ cdrkit 1.0 in breezy-autotest SUPERSEDED cprov
>> iceweasel 1.0 in breezy-autotest PUBLISHED mark
>>+ pmount 0.1-1 in warty PUBLISHED cprov
>>
>> 'getMostActiveP
>> containing up to 5 PPAs with the highest number of publications in the
>>@@ -1808,14 +1805,13 @@
>> ... a_pub.copyTo(
>> ... ubuntu['hoary'], PackagePublishi
>>
>>- >>> create_
>>+ >>> create_
>> >>> create_
>> >>> create_
>> >>> create_
>> >>> create_

This is the first branch in a series to refactor soyuz tests after fixing bug 506203.
The MP for the prerequisite branch that fixes the actual bug is at:
https:/ /code.edge. launchpad. net/~michael. nelson/ launchpad/ 506203- ppa-privatisati on-check/ +merge/ 19415
The fix ensures that the privacy of a PPA cannot be altered once it has packages published. Unfortunately most of our test infrastructure does exactly that (switches the privacy to do a few tests and then switches it back).
The breakages are as follows: pastebin. ubuntu. com/378292/
http://
This branch fixes:
bin/test -vv -t doc/archive.txt -t publisher- config. txt -t buildd-scoring.txt