Merge lp:~sinzui/launchpad/obsolete-add-edit into lp:launchpad
Status: | Merged |
---|---|
Approved by: | Paul Hummer |
Approved revision: | no longer in the source branch. |
Merged at revision: | 11711 |
Proposed branch: | lp:~sinzui/launchpad/obsolete-add-edit |
Merge into: | lp:launchpad |
Diff against target: |
833 lines (+251/-446) 12 files modified
lib/canonical/launchpad/templates/launchpad-addform.pt (+0/-81) lib/canonical/launchpad/templates/launchpad-editform.pt (+0/-104) lib/canonical/launchpad/zcml/configure.zcml (+0/-2) lib/canonical/launchpad/zcml/widgets.zcml (+0/-46) lib/lp/app/browser/configure.zcml (+14/-0) lib/lp/registry/browser/codeofconduct.py (+52/-118) lib/lp/registry/browser/configure.zcml (+6/-18) lib/lp/registry/browser/tests/test_codeofconduct.py (+149/-0) lib/lp/registry/stories/gpg-coc/98-cocacknowledge.txt (+30/-29) lib/lp/registry/templates/signedcodeofconduct-acknowledge.pt (+0/-16) lib/lp/registry/templates/signedcodeofconduct-activate.pt (+0/-16) lib/lp/registry/templates/signedcodeofconduct-deactivate.pt (+0/-16) |
To merge this branch: | bzr merge lp:~sinzui/launchpad/obsolete-add-edit |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Paul Hummer (community) | Approve | ||
Review via email: mp+38377@code.launchpad.net |
Description of the change
This is my branch to remove addform and editform.
lp:~sinzui/launchpad/obsolete-add-edit
Diff size: 710
Launchpad bug:
https:/
https:/
Test command: ./bin/test -vv \
-t coc -t codeofconduct
Pre-
Target release: 10.11
Remove addform and editform
-------
These two templates are only used for their macros.
lib/canonical
lib/canonical
These are the last templates to use them.
./lib/
./lib/
./lib/
Rules
-----
* Add tests for the existing behaviour
* Convert the views to LaunchpadFormView
* Update the ZCML to use the generic edit template
QA
--
As an admin, choose a user that has not signed the CoC to test with
* Visit https:/
* Search for the user and verify he does has not signed the CoC.
* Follow the register link.
* Enter the user's name and choose Register.
* Search for the user and view his signed CoC record.
* Verify his CoC is active.
* Choose to edit icon
* Add a comment and choose Deactivate.
* Verify the CoC now states it is inactive.
* Choose to edit icon
* Add a comment and choose Activate.
* Verify the CoC now states it is active.
Lint
----
Linting changed files:
lib/canonical
lib/lp/
lib/lp/
lib/lp/
lib/lp/
3: source has bad indentation.
12: source has bad indentation.
16: source exceeds 78 characters.
16: source has bad indentation.
23: source has bad indentation.
32: source has bad indentation.
^ I can fix this after the review. The indentation changes will make the diff
difficult to read.
Test
----
* lib/lp/
* Added tests for the signed CoC management views.
* lib/lp/
* Updated the story to use the information the user sees.
Implementation
--------------
* lib/canonical/
* Unregistered the deleted templates.
* I could move the two remaining templates to lp/app and extract
the last widget ZCML to lp/app/
file.
* lib/lp/
* Converted the AddView and EditView views into LaunchpadFormViews.
* This looks like a 100% rewrite in the diff, but I made these changes
using small refactorings. I am surprised I did this much.
* lib/lp/
* Replaced the add/edit ZCML with page ZCML.
The best kind of code to review is the kind that's getting removed. :) Thanks for sorting out some more tech debt.
Please fix the indentation issues raised by lint. Thank you for thinking of your reviewer when you saw those lint issues.