-
-
Notifications
You must be signed in to change notification settings - Fork 90
Regression tests for issue 312 #316
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
Regression tests for issue 312 #316
Conversation
β¦tests. Using the new error_log mock class inspect the value during the keep alive tests, previously ignoring the log caused the regression of issue cherrypy#313.
Co-authored-by: Sviatoslav Sydorenko <wk.cvs.github@sydorenko.org.ua>
Mainly moving class definition to the top level and adding more docstring. The most notable thing is the replacement of the fixture `testing_server` to `raw_testing_server` and move the error_log patching in a new one that will include that functionality using the old name `testing_server`.
@webknjaz I think I implemented all of the comments. Just a note on using Compare this run https://github.com/cherrypy/cheroot/runs/1018974455 vs https://github.com/cherrypy/cheroot/runs/1019226287 |
conn.close() | ||
self.socket_closed = True | ||
|
||
return self.original_get_map() |
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.
I'm a bit worried about self.original_get_map()
being called twice. Can it return different values for each invocation? Should it be called once and the result reused?
I think you can make it more verbose with something like |
I noticed some Python 2 issues after the merge, trying to address them in master. |
This change allows pytest to show the local variables' values in the error summary. Ref: #316 (comment)
β What kind of change does this PR introduce?
π What is the related issue number (starting with
#
)#312
β What is the current behavior? (You can also link to an open issue here)
Errors that causes issues #312 weren't detected by the testsuite.
β What is the new behavior (if this is a feature change)?
Detect the errors that caused issues #312
π Other information:
This PR implements the tests that are meant to be passed by PR #313, it expands the test coverage of the
coonections
module.π Checklist:
and description in grammatically correct, complete sentences
This change isβ