New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Do not start QueueProcesserThread on config update. #18
Conversation
... as "domain.com" is a real domain, and "example.com" should be used for both documenation and testing purposes. modified: src/Products/MailHost/tests/testMailHost.py
... as this is unexpected. modified: src/Products/MailHost/MailHost.py modified: src/Products/MailHost/tests/testMailHost.py
modified: src/Products/MailHost/tests/testMailHost.py
Jürgen Gmach wrote at 2019-5-28 06:59 -0700:
... as this is unexpected.
I'd be very happy to also cover the `if REQUEST` idiom, if somebody could point me to
- how to make a simple REQUEST object for testing (which I probably could figure out myself)
I typically use `Testing.ZopeTestCase.ZopeTestCase` as base
class for my Zope tests. It sets up a minimal Zope environment.
Especially, the test instance has a `self.app` (Zope's application root).
From this, you can get a test request with `self.app.REQUEST`.
If you have got Zope's application object ("app") in any way
(e.g. from a `zconsole`) you can wrap it into a test request
with `Testing.makerequest.makerequest`).
|
I wish you would not mix a completely unrelated cleanup of the email addresses used in the tests into this PR. Now you have a huge diff you're asking people to look at where very little actually concerns the issue in question. Please do not do that in the future. It makes reviewing unneccessarily hard. Thank you. |
It is somewhat pointless to test the ZMI redirect at the end. That code has not changed except for moving a single line around. Furthermore, the redirect is completely unrelated to the actual issue you're fixing here. I'm going to merge this as-in. |
An additional entry in the change log would be nice. |
@d-maurer Thanks a lot for pointing me to @dataflake Thanks for merging! When I work on code, I usually look for what Martin Fowler calls opportunistic refactoring or Robert Martin calls the boyscout rule = "always leave the code behind in a better state than you found it". I am well aware that reviews and therefore commits should be easy scannable. By the way... Did you notice that I put the domain name change into a separate commit? Anyway, if you prefer smaller pull requests, I will do so. |
I do not look at separate commit. I look at the final change set. You're welcome to use whatever technique you want, but if you end up with a large change set you're making life hard for the reviewer. We're all volunteers here who spend their spare time. You can always create separate PRs for unrelated changes. |
... as this is unexpected.
I'd be very happy to also cover the
if REQUEST
idiom, if somebody could point me toWith a super simple dummy request object(
request = {}
) I get this test error, which I do not know how to handle.This is the first pull request (for #14) - once accepted, I will make another one for the 2.13 branch, as I need a backport for my Zope app, which currently still runs on 2.13.