Commit graph

175 commits

Author SHA1 Message Date
Henrik Levkowetz aa5e61d958 Updated all urlpatterns to use ietf.utils.urls.url() instead of django's,
in order to autogenerate dotted path url pattern names.  Updated a number
of url reverses to use dotted path, and removed explicit url pattern names
as needed.

Changed some imports to prevent import of ietf.urls before django
initialization was complete.


Changed 3 cases of form classes being curried to functions; django 1.10
didn't accept that.

Started converting old-style middleware classes to new-style middleware
functions (incomplete).

Tweaked a nomcom decorator to preserve function names and attributes, like
a good decorator should.

Replaced the removed django templatetag 'removetags' with our own version
which uses bleach, and does sanitizing in addition to removing explicitly
mentionied html tags.

Rewrote the filename argument handling in a management command which had
broken with the upgrade.
 - Legacy-Id: 12818
2017-02-11 14:43:01 +00:00
Henrik Levkowetz 26fcce9c28 Brought back the nomcom nominee merge functionality which was inadvertently removed in January. There is now both a Merge Nominee and a Merge Person form, with additional instructions which should make it easier to choose the right one for the task.
- Legacy-Id: 12017
2016-09-22 14:23:20 +00:00
Henrik Levkowetz 4b0a9360f0 Merged in ^/branch/iola/event-saving-refactor-r10291, which refactors document saving to always use doc.save_with_history(events), and requires accompanying events. This branch also provides refactoring of recurring regexes in url patterns into a dictionary. As part of the merge, also refactored new code which didn't use the save_with_history() method.
- Legacy-Id: 11840
2016-08-23 10:52:08 +00:00
Henrik Levkowetz e6a005dba6 Added a score of setting save/restores to test setup/teardown actions.
- Legacy-Id: 11436
2016-06-21 07:51:02 +00:00
Henrik Levkowetz e552ff85b7 Tentatively comment out use of tempdir() in nomcom.tests.
- Legacy-Id: 10704
2016-01-16 22:30:05 +00:00
Robert Sparks dc5ae398f2 Improved SearchablePersonField to show the primary email address for any search results where a name appears more than once.
Simplified the edit nominee form.
Replaced the merge nominee form with a request to the secretariat to merge Person records. Fixes #1847.
Added merging nominees to the secretariat's person merging script.
Restructured the person merging script to make it testable.
Updated some tests to match changes to the mailtriggers that hadn't made it to the fixtures.
 - Legacy-Id: 10625
2015-12-22 21:42:55 +00:00
Robert Sparks aadcf2d056 Added selecting existing people to the workflow for chair classification of nominations. Renamed some utility functions to be slightly more self-documenting.
- Legacy-Id: 10620
2015-12-22 04:32:48 +00:00
Robert Sparks fa53de03e3 Guide the workflow back to normal nominations after nominating a new person.
- Legacy-Id: 10619
2015-12-21 21:01:23 +00:00
Robert Sparks 85c13d65b4 Replaced the custom message infrastructure in the nomcom app with django.contrib.messages
- Legacy-Id: 10618
2015-12-21 20:46:56 +00:00
Robert Sparks 8261507e80 Added forms for the exceptional "create a new person for this nomination" workflow. Checkpointing before a round of simplification refactors.
- Legacy-Id: 10610
2015-12-18 23:11:24 +00:00
Robert Sparks 6bf4227974 Checkpoint: main nomination forms use SearchableEmailField
- Legacy-Id: 10609
2015-12-18 20:38:17 +00:00
Robert Sparks de0b7c9a37 Checkpoint: views tests at 96%
- Legacy-Id: 10606
2015-12-16 23:12:40 +00:00
Robert Sparks df571c2fcc Improved test coverage (from 66 to 87%) - checkpointing before removing move_to_default
- Legacy-Id: 10602
2015-12-16 11:51:32 +00:00
Robert Sparks 9ddcd62c44 Allow nominees to add a comment when accepting or declining. Fixes #1845.
- Legacy-Id: 10589
2015-12-14 03:26:43 +00:00
Robert Sparks ea6d82846f Avoiding an initialization problem by setting NOMCOM_PUBLIC_KEYS_DIR in settings_sqlitetest. This is not the best long term fix
- Legacy-Id: 10581
2015-12-11 17:30:13 +00:00
Robert Sparks 3bc615883d normalizes management of a test directory for test nomcom public keys
- Legacy-Id: 10574
2015-12-11 04:01:11 +00:00
Robert Sparks b653e8fe8a Removed the description field from Position. Simplified the Position list and the Position edit form. Tweaked several places to make the pages more self documenting. Added a page to help nomcom chairs through setting up a new nomcom. Fixes #1867 and #1768.
- Legacy-Id: 10565
2015-12-09 23:24:46 +00:00
Robert Sparks f566a83d1d Captured when nomcom members reviewed feedback for a given nominee last. Added badges when new feedback is available. Improved layout of feedback index page. Fixes #1850.
- Legacy-Id: 10535
2015-12-02 23:25:42 +00:00
Robert Sparks 5bafd3d8fe Conditioned behavior of views for concluded nomcoms. Fixes #1856.
- Legacy-Id: 10521
2015-11-28 21:51:37 +00:00
Robert Sparks e81b473282 Expose views for concluded nomcoms. Close feedback and nomination. Initial work on factory-boy based testing. Partially addresses #1856
- Legacy-Id: 10520
2015-11-25 22:17:41 +00:00
Robert Sparks 00e5762e20 Simplify the nomcom feedback comment form. Make that more obvious who receives mail when that form is used. Fixes #1849.
- Legacy-Id: 10501
2015-11-16 21:46:29 +00:00
Henrik Levkowetz cf7d794b09 Modified the test data to use some AD and WG chair names that contain non-ascii characters, and fixed test issues found.
- Legacy-Id: 10418
2015-11-04 07:34:56 +00:00
Ole Laursen 86c3a430d1 Merge in ^/branch/iola/event-saving-refactor-r10076, fixing a few problems
- Legacy-Id: 10298
2015-10-27 10:37:06 +00:00
Henrik Levkowetz 4a80395a63 Removed support for perma_fixtures, using the blobal test fixtures instead.
- Legacy-Id: 10228
2015-10-18 11:49:15 +00:00
Ole Laursen 73a41bb7e6 Summary: Fix problem with three NomCom tests that had a hard-coded id,
which doesn't necessarily work with the way transactions work in MySQL
 - Legacy-Id: 10190
2015-10-12 15:03:00 +00:00
Robert Sparks 8a74604a1b Done with the second pass focusing on test coverage. Lots of test tweaks, some new tests, a couple of bugs fixed. The session request code views need to be redone to allow testing.
- Legacy-Id: 10035
2015-08-21 16:39:00 +00:00
Robert Sparks 83753dd24e Tests nomcom confirmation receipts. Fixes bug in submission blackout test where test was using local time, but view was using utc
- Legacy-Id: 10034
2015-08-20 04:23:40 +00:00
Henrik Levkowetz 85f9eee27b Updated a set of nomcom tests to account for new facelift DOM attributes.
- Legacy-Id: 9361
2015-04-02 19:49:11 +00:00
Henrik Levkowetz 625347cd2f Merged trunk@9354 to facelift copy
- Legacy-Id: 9357
2015-04-02 06:51:34 +00:00
Joel M. Halpern 8cab64c2fe added some nomcom test cases. Commit ready for merge.
- Legacy-Id: 9317
2015-03-21 22:37:43 +00:00
Henrik Levkowetz ddbb8c18a5 Updated the nomcom tests to use temporary test directories for data, instead of the regular values in settings.py
- Legacy-Id: 9248
2015-03-19 17:52:31 +00:00
Ole Laursen a3399b0bcd Summary: Port remaining parts of nomcom to bootstrap, fix some bugs,
let the private/public feedback pages share the same template, remove
the edit NomCom chair thing - there's no link to it and the
Secretariat can instead use the ordinary group management tool they
have available
 - Legacy-Id: 8721
2014-12-02 10:43:20 +00:00
Ole Laursen 87870ca954 Fix more test errors - now only two not yet fully ported views remain
- Legacy-Id: 8571
2014-11-03 16:39:41 +00:00
Henrik Levkowetz 0d61e270d6 Normalized a couple of NameModels subclasses.
- Legacy-Id: 8460
2014-10-23 21:14:41 +00:00
Henrik Levkowetz b02b0a96df All tests pass, except for some pyflakes tests which I believe are fixed in trunk.
- Legacy-Id: 7579
2014-04-06 20:04:36 +00:00
Henrik Levkowetz 563f584a9e Made ietf/nomcom pyflakes-clean. Removed some dead code.
- Legacy-Id: 7476
2014-03-15 19:26:01 +00:00
Ole Laursen 892c7d43ce Reuse already fetched page instead of refetching it in nomcom test
- Legacy-Id: 6922
2013-12-13 16:47:57 +00:00
Ole Laursen b302ffa814 Fix bug in nomcom test, it was sending a formset without the
corresponding management form values
 - Legacy-Id: 6921
2013-12-13 16:45:04 +00:00
Ole Laursen aea222edbc Speed up nomcom tests a bit more by also only generating one certificate for the client per run
- Legacy-Id: 6920
2013-12-13 16:28:55 +00:00
Ole Laursen 652a5ca17a Rewrite NomCom test data generation slightly based on the rewritten
base test data, fix problem with form previews
 - Legacy-Id: 6918
2013-12-13 15:59:52 +00:00
Ole Laursen e32d346bc5 Fix security_hash problem in nomcom tests, it's no longer a separate function
- Legacy-Id: 6905
2013-12-13 13:10:52 +00:00
Ole Laursen d0f2859631 Move NomCom announcements view to nomcom/, move message view to
message/, add tests, add redirects, fix a couple of small bugs in the
announcements view
 - Legacy-Id: 6769
2013-11-28 17:55:10 +00:00
Ole Laursen 9457669310 Merge in changes from the old shimfree branch
- Legacy-Id: 6764
2013-11-27 12:55:50 +00:00
Henrik Levkowetz 5f2da7ba9e Merged [6486] from rjsparks@nostrum.com:
Slightly more than minimal changes to have questionnaire reminders go only to those nominees who have accepted but have not yet sent in a questionnaire for a given position
 - Legacy-Id: 6573
Note: SVN reference [6486] has been migrated to Git commit 2a1b4c7775
2013-10-30 21:17:46 +00:00
Henrik Levkowetz d649fd5e10 Merged [6465] and [6466] from rjsparks@nostrum.com:
Added the ability to send reminders to complete questionnaires to nominees in
the accepted state.  Changed the send_reminders management command to not take
any arguments and run against all active nomcoms.  Removed bugs from the
send_reminders management command and added tests for it.  Adjusted several
dbtemplate titles and content.

Fixes bug 1157
 - Legacy-Id: 6471
Note: SVN reference [6465] has been migrated to Git commit 22f356434a

Note: SVN reference [6466] has been migrated to Git commit a461e6c4a4
2013-10-21 20:12:00 +00:00
Henrik Levkowetz e4f4467725 Changed tests to use our own subclassed TestCase, and changed almost all fixtures to be perma_fixtures.
- Legacy-Id: 6320
2013-09-30 20:36:20 +00:00
Ole Laursen c191a691e0 Remove "names" fixture from all tests, since it's now loaded once just
after creating the test database through the global test fixture
mechanism - this speeds up multiple tests considerably
 - Legacy-Id: 6305
2013-09-29 17:35:59 +00:00
Henrik Levkowetz 6baea429aa Merged in the nomcom app from ejimenez@yaco.es and esanchez@yaco.es, and accompanying dbtemplate app and the (standard) docutils module. Added some tweaks to get all tests to pass and migrations to run.
- Legacy-Id: 5948
2013-08-06 10:09:29 +00:00
Emilio Jiménez ddbfdf4b7b change merge form, accepted vs any state: accepted, pending vs declined: declined
Fixes #1016
 - Legacy-Id: 5701
2013-05-07 11:50:13 +00:00
Emilio Jiménez c3ff510ed0 Change questionnaire response view.
Fixes #1007
 - Legacy-Id: 5689
2013-05-02 09:42:00 +00:00
Emilio Jiménez 8182518242 Fixed questionnaire test
Ver #970
 - Legacy-Id: 5686
2013-04-24 06:15:31 +00:00
Emilio Jiménez 85ab39f1ab Refactor feedback, now feedback belong many to many nominees
See #913 #929 #930 #965 #970 #975
 - Legacy-Id: 5598
2013-03-26 13:35:58 +00:00
Emilio Jiménez 69c704de2d better errors control in feedback form.
See #970
 - Legacy-Id: 5593
2013-03-25 18:02:00 +00:00
Emilio Jiménez c5c33c29bc Refactor nominee merge and more test
See #930
 - Legacy-Id: 5588
2013-03-22 12:34:19 +00:00
Emilio Jiménez 34af67420c fixed error questionnaire test.
See #970
 - Legacy-Id: 5587
2013-03-22 10:35:41 +00:00
Emilio Jiménez 35f75289e3 Add questionnarie test.
See #970
 - Legacy-Id: 5586
2013-03-22 10:32:52 +00:00
Emilio Jiménez 139ab194c9 Add questionnaire skel view
Add feedback test
Fixed labels in feedback form
See #970
 - Legacy-Id: 5582
2013-03-21 18:33:02 +00:00
Emilio Jiménez 55e843a4d8 refactor public key test.
See #905
 - Legacy-Id: 5581
2013-03-21 12:26:45 +00:00
Emilio Jiménez 40fd14da25 * Add skek view to manage feedback generated from email.
* Now, nominee, type and user fields in feedback model can be null
See #975
 - Legacy-Id: 5576
2013-03-17 21:34:25 +00:00
Emilio Jiménez 4fec10183d Feedback refactor:
* Now Feedback have manytomany to posotions, so a feedback email can be associated to few positions.
 * Add user and time field to nomination model
 * Delete feedbacks and questionnaires field from nomineeposition model, now feedback model has all information about nominations, feedback and quiestionnaires
 * Add user field to Feedback model to know the nomcom meber who made the nomination, regardless of the real author
 * Add nomcom field to Feedback and refactor EncryptedTextField, it's necessary to encrypt the comments with the nomcom public key.
 * Template tag to decrypt feedback has been improved, now It isn't necessary the view context has the private key variable.
 * Add skel view to view feedback
 * Delete hidden fields from private and public feedback form
 * Refactor private index view to show total number of questionnaires and to show if the nomienee has questionnaires or not
See #970
 - Legacy-Id: 5571
2013-03-15 10:05:28 +00:00
Emilio Jiménez 04ab58d1ae Add test skel for feedback
See #970
 - Legacy-Id: 5549
2013-03-11 07:52:23 +00:00
Emilio Jiménez bf0747a8e9 Add duplicated field for nominees, it is necesary when chair marks duplicate nominations
Change questionnaires field in NomineePosition model to manytomany, becouse it is necessary whe chair marks duplicate nominations.
Add timestamp in NomineePosition objects to see wich nomineeposition object is the last one.
Better merge nominations, update questionnaires and state of primary nomineposition object
See #930
 - Legacy-Id: 5187
2013-01-15 16:14:00 +00:00
Emilio Jiménez 69a93c9f92 Check nomcom of nominations and that email is a nominee
See #930
 - Legacy-Id: 5184
2013-01-15 10:59:44 +00:00
Emilio Jiménez 7e830643e5 Add nominee merge view.
See #930
 - Legacy-Id: 5183
2013-01-14 19:00:25 +00:00
Emilio Jiménez de7bab7de4 Add nomination private process
See #929
 - Legacy-Id: 5180
2013-01-13 20:34:27 +00:00
Emilio Jiménez 57ccf2d5fc delete comment
See #905
 - Legacy-Id: 5171
2013-01-03 21:19:50 +00:00
Emilio Jiménez ec0429ed39 Add edit public key test
See #905
 - Legacy-Id: 5170
2013-01-03 21:17:53 +00:00
Emilio Jiménez 4b00c329cf Add nominate test.
See #913
 - Legacy-Id: 5169
2013-01-03 20:15:19 +00:00
Emilio Jiménez 7e3a6a3cff * Add nominate test
* If nomcom doesn't have public key, community users wont can nominate.
See #913
 - Legacy-Id: 5166
2013-01-03 17:31:34 +00:00
Emilio Jiménez 9f9c7953ab Add edit members test.
See #904
 - Legacy-Id: 5164
2013-01-03 15:36:28 +00:00
Emilio Jiménez 140ebaad31 * Fix some decorators in private index and private merge views
* Add edit chair test
 * Add new roles in nomcom_test_data function
 * Add member rolename to name app fixtures
 * Change urls names
See #904 #919
 - Legacy-Id: 5163
2013-01-03 14:40:34 +00:00
Emilio Jiménez 5e3e4bfd2e Add a test to check encrypted feedback
Ver #913
 - Legacy-Id: 5157
2012-12-27 11:57:36 +00:00
Emilio Jiménez e42b5015e7 Add navigation bar for nomcom pages.
Add views and template skel for nomcom pages.
Modify nomcom templates fixtures
Modify initialize functions for nomcom templates
Add view tests for nomcom pages.
Add navset styles for horizontal items
See #919
 - Legacy-Id: 5152
2012-12-25 11:39:36 +00:00
Emilio Jiménez eb8b6af4ed * Add news fixtures of name for testing
* Add test data fuction for testing
* Add test case to check the default state and the unique constraint in NomineePosition class
* Override the save fuction of the NomineePosition class to set the state to pending by default
See #909
 - Legacy-Id: 5127
2012-12-14 18:53:10 +00:00
Emilio Jiménez 230f6cfae7 view only accessible by the secretariat that allows to assign the email of the members and the chair of the NomCom
See #904
 - Legacy-Id: 5066
2012-11-20 00:40:57 +00:00