Merge lp:~sinzui/launchpad/api-bug-tracker-0 into lp:launchpad
Status: | Merged |
---|---|
Approved by: | Edwin Grubbs |
Approved revision: | no longer in the source branch. |
Merged at revision: | not available |
Proposed branch: | lp:~sinzui/launchpad/api-bug-tracker-0 |
Merge into: | lp:launchpad |
Diff against target: |
164 lines (+106/-1) 3 files modified
lib/canonical/launchpad/security.py (+5/-0) lib/lp/bugs/interfaces/bugtracker.py (+24/-1) lib/lp/bugs/stories/webservice/xx-bug-tracker.txt (+77/-0) |
To merge this branch: | bzr merge lp:~sinzui/launchpad/api-bug-tracker-0 |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Edwin Grubbs (community) | code | Approve | |
Review via email: mp+21061@code.launchpad.net |
Description of the change
This is my branch to export bugtrackerset over the api.
lp:~sinzui/launchpad/api-bug-tracker-0
Diff size: 129
Launchpad bug: https:/
Test command: ./bin/test -vv \
-t webservice/
Pre-
Target release: 10.03
Export bugtrackerset over the api
-------
Export the bugtrackerset of the api so that ensureBugTracker() can be
used in API operations. We want a formoverlay to register an new bugtracker
when user discovers that the bug tracker he wants to set to the project is
not registered.
Rules
-----
* Export IBugTrackerSet and ensureBugTracker
QA
--
* Verify that you can get the IBugTrackerSet via anonymous api
* Verify that you can use ensureBugTracker() to register a tracker
logged in.
Lint
----
Linting changed files:
lib/canonical
lib/lp/
lib/lp/
Test
----
* lib/lp/
* Added tests to verify that IBugTrakerSet is exported for anonymous
Use. Added a test to verify that ensureBugTracker can create a
new bugtracker.
Implementation
--------------
* lib/canonical/
* Added a security checker for IBugTracker to ensure anonymous users
can see them.
* lib/lp/
* Exported IbugTrackerSet with search and ensureBugTracker methods.
Hi Curtis,
This branch looks good. Just one comment below.
merge-conditional
-Edwin
>=== added file 'lib/lp/ bugs/stories/ webservice/ xx-bug- tracker. txt' bugs/stories/ webservice/ xx-bug- tracker. txt>*1970- 01-01 00:00:00 +0000 bugs/stories/ webservice/ xx-bug- tracker. txt>*2010- 03-10 16:34:01 +0000 testing. webservice import ( collection = anon_webservice .get( bugtrackers' ).jsonBody( ) collection( bug_tracker_ collection) _link: api.launchpad. dev/beta/ bugs/bugtracker s?ws.start= 5&ws.size= 5'
>--- lib/lp/
>+++ lib/lp/
>@@ -0,0 +1,62 @@
>+Bug tracker
>+===========
>+
>+The bug tracker set is exported as a collection at /bugs/bugtrackers that
>+any user can access.
>+
>+ >>> from lazr.restful.
>+ ... pprint_collection, pprint_entry)
>+
>+ >>> bug_tracker_
>+ ... '/bugs/
>+ >>> pprint_
>+ next_collection
>+ u'http://
Normally, "api.launchpad. dev/beta" is replaced with "..." so that the test doesn't break when the default version changes.
Please replace all the other instances also.