summaryrefslogtreecommitdiff
path: root/src/mailman/app/tests/test_moderation.py (follow)
Commit message (Collapse)AuthorAgeFilesLines
* Bump copyright years.Barry Warsaw2017-01-041-1/+1
|
* Fix flake8 errors.Mark Sapiro2016-12-041-1/+2
|
* Fix tests for test-owner instead of moderator's address.Mark Sapiro2016-12-041-1/+1
|
* Closes: #68Barry Warsaw2016-11-131-6/+13
| | | | | Messages sent to the list's moderators now include the actual recipient addresses. Given by Tom Briles.
* Issue 68: send messages to list moderators when tomoderators=TrueTom Briles2016-10-311-1/+9
|
* 99% test coverage.Barry Warsaw2016-10-211-2/+6
| | | | | | | | | Also: * Ignore coverage in the testing submodule. * Remove some unreachable code. * Spelling. * Fix a bug in run_thru().
* Simplify the implementation.Barry Warsaw2016-10-171-3/+2
| | | | | | | | | | | | | | | | | | | | | | This merges the SubscriptionManager and UnsubscriptionManager into a single SubscriptionManager implementation that handles both register() and unregister(). This allows us to use direct class-based adaptation instead of the more clunky getAdapter() API. We can also eliminate the funky _get_workflow() implementation detail. This has a couple of side-effects. .confirm() must lookup the token in the pendings database and pull out the pending type, dispatching to the proper class depending on the type, or raising a LookupError if the token is None or there is no pendable associated with the given token. This feels like an acceptable trade-off. However, this *also* means that IWorkflowStateManager must lose its 'name' argument in its methods. That's because we won't actually know the name until its too late. Honestly, the name wasn't providing much value anyway (it was always the subclass's name), so losing that seems fine too. The complication here is that the name was a primary key in the 'workflowstate' table, so we need to add its removal in the database migration.
* flake8 fixes.Barry Warsaw2016-10-161-2/+2
|
* CheckpointingBarry Warsaw2016-09-011-2/+2
|
* Intermediate CommitAbhilash Raj2016-09-011-3/+4
|
* First massive round of cleanups.Barry Warsaw2016-03-231-16/+8
| | | | | | | | * Get rid of explicit __all__ settings and use the @public decorator. * Get rid of ^L's * Use expected_count argument for get_queue_messages() * Various code modernizations. * Other minor changes to make flake8 happy.
* Fix cross-posting held on more than one list.Barry Warsaw2016-03-081-23/+13
| | | | | | | | | | | Closes #176 Also: * IMessageStore no longer raises a ValueError if the Message-ID already exists in the store; it just returns None. * The internal handle_message() function no longer takes a `preserve` argument, since messages are never removed from the IMessageStore.
* Happy New Year.Barry Warsaw2016-01-021-1/+1
|
* Handle deleting nonexistent messages from the message store. Closes: #167Aurélien Bompard2015-12-021-0/+9
|
* Remove old APIs handle_subscription() and hold_subscription().Barry Warsaw2015-05-021-10/+10
|
* * Refactor add_member() so that it uses a RequestRecord namedtuple.Barry Warsaw2015-03-211-1/+29
| | | | | | * RequestRecord contains no password key so these are not part of the held requests database any more. * Pending record contains `email` now instead of `address`.
* Bump copyright years.Barry Warsaw2015-01-041-1/+1
|
* Remove huge amounts of now unnecessary file boilerplate.Barry Warsaw2014-12-221-5/+1
|
* Bump copyright years.Barry Warsaw2014-01-011-1/+1
|
* Bump copyright years.Barry Warsaw2013-01-011-1/+1
|
* * Simplify moderator.rst and requests.rst so they serve a better purpose asBarry Warsaw2012-12-171-6/+40
| | | | | | | | | | documentation. Move non-documentation tests into a separate unittest file. * Separate out the doctests for IRequest from the doctests for app/moderator.py and place the latter in a separate file. * Fix typo in app/membership.py (s/send_goodbye_msg/send_goodbye_message), but LP: #1091321 tracks more needed fixes in this area.
* ConfigurationBarry Warsaw2012-11-041-3/+0
| | | | | | | | | | | | | | | ------------- * `[passlib]path` configuration variable renamed to `[passlib]configuration`. * Postfix-specific configurations in the `[mta]` section are moved to a separate file, named by the `[mta]configuration` variable. * In the new `postfix.cfg` file, `postfix_map_cmd` is renamed to `postmap_command`. Also: * More Python 2.7-isms, use assertMultiLineEqual() directly. * Added external_configuration() and load_external() to mailman.config.config * ConfigLayer does a blanket set of [postfix]postmap_command so subtests generally won't have to.
* * Non-unicode values in msgdata broke pending requests. (LP: #1031391)Barry Warsaw2012-08-171-0/+12
|
* * Fix `test_moderation` for timezones East of UTC+0000, given by blacktav.Barry Warsaw2012-03-121-3/+4
| | | | (LP: #890675)
* Consistent use of assertMultiLineEqual().Barry Warsaw2012-03-061-3/+2
|
* * Held messages can now be moderated through the REST API. Mailing listBarry Warsaw2012-01-301-0/+14
| | | | | | | | | | | | | | | resources now accept a `held` path component. GETing this returns all held messages for the mailing list. POSTing to a specific request id under this url can dispose of the message using `Action` enums. * `IRequests` interface is removed. Now just use adaptation from `IListRequests` directly (which takes an `IMailingList` object). * `handle_message()` now allows for `Action.hold` which is synonymous with `Action.defer` (since the message is already being held). * `IListRequests.get_request()` now takes an optional `request_type` argument to narrow the search for the given request. - also, print_function is now a standard __future__ import. The template has been updated, but add this to modules as you edit them.
* copybumpBarry Warsaw2012-01-011-1/+1
|
* Remove extraneous `test_suite()` functions. zope.testrunner willBarry Warsaw2011-10-301-8/+0
| | | | | | | | | automatically do the right thing in most cases. Keep test_suite() in test_documentation.py since these dynamically set up docs tests properly. Refactor test_passwords.py so that base class tests aren't bogusly run. Also, remove test_membership.py which was essentially disabled because it was testing the MM2 membership API.
* * Rewrote a test for compatibility between Python 2.6 and 2.7. (LP: #833208)Barry Warsaw2011-09-071-24/+15
|
* * Local timezone in X-Mailman-Approved-At caused test failure. (LP: #832404)Barry Warsaw2011-08-231-4/+12
|
* * Moderating a message with Action.accept now sends the message. (LP: #827697)Barry Warsaw2011-08-221-0/+106
Also: * Use utilities.datetime.now() so that moderation related dates are predictable during the test suite. * When a message is accepted, drop it in the pipeline queue. The above bug was caused by the message going in the incoming queue, and then being re-moderated. * Expose mailman.bin.master.Loop in __all__. * Add some helpful debug logging.