-
Notifications
You must be signed in to change notification settings - Fork 36
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
Performance improvement #66
Conversation
theseion
commented
Nov 9, 2021
•
edited
Loading
edited
- Reworked http module to run tests much faster by removing most of the timeouts.
- Updated dependencies
- Added Python 3.10
- Fixed a couple of deprecations
The marker methods are called by the test runner and enable the log checker to perform setup actions before the request is sent and after the response has been received
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.
Wow @theseion I love what I am seing here! So moving to select gives us probably way better efficiency. And only reading time if we are going to use it, nice catch. I wonder why the time.sleep
was being used, maybe @fgsch has better idea. Also, he might know more if this might affect upstream users.
Other questions:
- Do we need to update documentation to reflect on these changes?
- Is there any additional test we should consider on adding, just to be safe?
Cool, @theseion. For the record, we still plan to move to go-ftw with the project, so this is simply cool, nice2have and good for ftw, but without long term impact as far as CRS is concerned. Correct? |
That is correct. It's mainly for me, so I can run tests for the changes I'm making to the regexp-assemble stuff. |
Thank you. It's very nice to PR these fixes nevertheless. |
The additional data can be used to generate unique ID's for individual tests
Fixed fixture name in pytest_generate_tests
I have this version working now with the CRS test suite. The tests for Apache all pass. The tests for NGiNX don't but at least the failures are now stable (with the current setup we have random failures). I've also taken the opportunity to update dependencies but that can easily be split into a separate pull request if necessary. |
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. As there is a small change for the Windows platform, should we fire tests using Windows also?
Yes, that's probably a good idea. Do you have it set up on a Windows machine? |
I ran the tests on my Windows machine (Windows 11) in Powershell. There's one test that is flaky but it's also flaky on macOS (example.com sometimes returns 404 instead of 200 for "Test multipart using list"). Otherwise, everything looks good. |
@fgsch I think this one is ready. Do you have any comments here? |
👋 I'm adding comments as I go through this PR (so far non-blockers). |
…eouts Split from PR coreruleset#66, part 1
Added test build for Python 3.10 Split from PR coreruleset#66, part 2
Added test build for Python 3.10 Split from PR coreruleset#66, part 2
…eouts Split from PR coreruleset#66, part 1