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
test helpers: add functionality for sending emails #3026
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
georglauterbach
added
area/security
kind/improvement
Improve an existing feature, configuration file or the documentation
service/security/rspamd
labels
Jan 25, 2023
polarathene
previously approved these changes
Jan 25, 2023
This was referenced Jan 26, 2023
Closed
georglauterbach
changed the title
rspamd: follow-up of #3016
test helpers: add functionality for sending emails
Jan 28, 2023
This was not planned, but as @polarthene mentioned in #3033 (comment) , filtering the mail log by email ID would be (the only) correct approach for the Rspamd test (to eliminate race conditions). I asserted the currect state, and came to the conclusion that this might (or actually is) something we want in more than one place. So I went ahead and implemented a solution. The solution for acquiring the ID is a bit slower because it ensures the mail queue is empty _before_ and _after_ the mail is sent. This is the tradeoff one has to make if they want to send multiple emails in one test file and get their IDs. I hope you like this approach. I will provide another PR that adjusts our current tests to use these new functions.
I think our work for our custom test framework should be noted in the docs for newcomers to better understand what they should do.
georglauterbach
force-pushed
the
rspamd/3
branch
from
January 28, 2023 14:15
0a1651e
to
3e98e5c
Compare
georglauterbach
added
kind/new feature
A new feature is requested in this issue or implemeted with this PR
area/tests
and removed
area/security
kind/improvement
Improve an existing feature, configuration file or the documentation
service/security/rspamd
labels
Jan 28, 2023
polarathene
approved these changes
Jan 29, 2023
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM 👍
Nice new helpers btw; thanks for the commit messages as added context and of course the documentation! 😀
casperklein
approved these changes
Jan 29, 2023
Documentation preview for this PR is ready! 🎉 Built with commit: cfca305 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
area/tests
kind/new feature
A new feature is requested in this issue or implemeted with this PR
priority/high
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
A small follow-up for things I noticed while getting Rspamd to work today. I should have thought about the permissions issue before, sorry. The disasbled modules were adjusted as well.I can report though that Rspamd works nicely on my setup now :DUPDATE: Correction; it works like a charm! It handles DKIM signing now (RSA+ED25519) & DNSBLs properly.This PR was a Rspamd PR, now it is a test functions PR needed for continueing with Rspamd and other PRs (such as #3033).
Type of change
Checklist:
docs/
)