Merge lp://staging/~michael.nelson/launchpad/496862-ppa-installable-binaries into lp://staging/launchpad
Status: | Rejected |
---|---|
Rejected by: | Michael Nelson |
Proposed branch: | lp://staging/~michael.nelson/launchpad/496862-ppa-installable-binaries |
Merge into: | lp://staging/launchpad |
Diff against target: |
675 lines (+240/-89) 10 files modified
lib/lp/soyuz/browser/archive.py (+79/-40) lib/lp/soyuz/browser/tests/archive-views.txt (+51/-37) lib/lp/soyuz/browser/tests/test_archive_view.py (+59/-0) lib/lp/soyuz/doc/archive.txt (+14/-4) lib/lp/soyuz/interfaces/archive.py (+7/-0) lib/lp/soyuz/model/archive.py (+23/-1) lib/lp/soyuz/templates/archive-copy-packages.pt (+1/-1) lib/lp/soyuz/templates/archive-delete-packages.pt (+1/-1) lib/lp/soyuz/templates/archive-index.pt (+1/-1) lib/lp/soyuz/templates/archive-macros.pt (+4/-4) |
To merge this branch: | bzr merge lp://staging/~michael.nelson/launchpad/496862-ppa-installable-binaries |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Jonathan Lange (community) | Approve | ||
Review via email:
|
Description of the change
This branch is the first of two to address bug 496862.
It adds an ArchiveArchFactory to create a vocabulary dynamically depending on the binaries published in the archive.
The ArchiveSourcePa
Finally, the ArchiveView (for the PPA index page) is updated to present binary packages.
The next branch will switch the PPA index ui to present the binary packages.
To test:
bin/test -vv -t archive-views.txt -t archive.txt -t TestArchiveView
Unmerged revisions
- 10545. By Michael Nelson
-
test style method renames.
- 10544. By Michael Nelson
-
Refactored dynamic vocabularies to functions rather than classes.
- 10543. By Michael Nelson
-
Removed branch todos as they're done.
- 10542. By Michael Nelson
-
Removed lint
- 10541. By Michael Nelson
-
Added unit tests for ArchiveView.
batched_ packages. - 10540. By Michael Nelson
-
Added filtered binary packages to the ArchiveView.
- 10539. By Michael Nelson
-
Adds IArchive.
arches_ with_binaries. - 10538. By Michael Nelson
-
Added failing test for IArchive.
arches_ with_binaries. - 10537. By Michael Nelson
-
A few more s/sources/packages renaming.
- 10536. By Michael Nelson
-
Initial renaming to re-use ArchivePackages
ViewBase for both source and binary
package listings.
On Thu, Mar 18, 2010 at 9:24 AM, Michael Nelson ckageListViewBa se class is refactored to ArchivePackages ViewBase so that it can be re-used for both source and binary packages.
<email address hidden> wrote:
> Michael Nelson has proposed merging lp:~michael.nelson/launchpad/496862-ppa-installable-binaries into lp:launchpad/devel.
>
> Requested reviews:
> Canonical Launchpad Engineering (launchpad)
>
>
> This branch is the first of two to address bug 496862.
>
> It adds an ArchiveArchFactory to create a vocabulary dynamically depending on the binaries published in the archive.
>
> The ArchiveSourcePa
>
> Finally, the ArchiveView (for the PPA index page) is updated to present binary packages.
>
> The next branch will switch the PPA index ui to present the binary packages.
>
> To test:
> bin/test -vv -t archive-views.txt -t archive.txt -t TestArchiveView
>
Good patch. I like the tests and the renames.
Some minor issues with method names and docstring formatting and a
couple of questions.
jml
> -- /code.launchpad .net/~michael. nelson/ launchpad/ 496862- ppa-installable -binaries/ +merge/ 21623 soyuz/browser/ archive. py' soyuz/browser/ archive. py 2010-03-10 12:50:18 +0000 soyuz/browser/ archive. py 2010-03-18 09:24:24 +0000 y(series_ terms) bularyFactory: IContextSourceB inder) arches_ with_binaries: architecturetag , displayname) append( term) y(arch_ terms)
> https:/
> Your team Launchpad code reviewers from Canonical is subscribed to branch lp:launchpad/devel.
>
> === modified file 'lib/lp/
> --- lib/lp/
> +++ lib/lp/
> @@ -589,6 +589,26 @@
> return SimpleVocabular
>
>
> +class ArchiveArchVoca
> + """A factory for generating vocabularies of an archive's arches in
> + a given distroseries."""
> +
> + implements(
> +
> + def __call__(self, context):
> + """Return a vocabulary created dynamically from the context archive.
> +
> + :param context: The archive used to generating vocabulary.
> + """
> + arch_terms = []
> + for arch in context.
> + term = SimpleTerm(
> + arch, token=arch.
> + title=arch.
> + arch_terms.
> + return SimpleVocabular
> +
Why is this a class and not a function? Is the implements() bit really
important?
> === added file 'lib/lp/ soyuz/browser/ tests/test_ archive_ view.py' soyuz/browser/ tests/test_ archive_ view.py 1970-01-01 00:00:00 +0000 soyuz/browser/ tests/test_ archive_ view.py 2010-03-18 09:24:24 +0000 launchpad. ftests import login onalLayer tests.test_ publishing import SoyuzTestPublisher initialized_ view (TestCaseWithFa ctory): onalLayer
> --- lib/lp/
> +++ lib/lp/
> @@ -0,0 +1,59 @@
> +# Copyright 2010 Canonical Ltd. This software is licensed under the
> +# GNU Affero General Public License version 3 (see the file LICENSE).
> +
> +"""Test the main PPA (user) view functionality."""
> +
> +__metaclass__ = type
> +
> +import unittest
> +
> +from canonical.
> +from canonical.testing import LaunchpadFuncti
> +from lp.soyuz.
> +from lp.testing import TestCaseWithFactory
> +from lp.testing.views import create_
> +
> +
> +class TestArchiveView
> +
> + layer = LaunchpadFuncti
> +
You need the librarian?
> + def setUp(self)...