-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
Python: Add tests for functional-like programming #17765
base: main
Are you sure you want to change the base?
Conversation
This can also serve for a place to add tests for constructs like threading.Thread, mulitprocess.Process, concurrent.futures.ThreadPoolExecutor, and concurrent.futures.ProcessPoolExecutor.
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.
A few comments, otherwise this looks like a handy set of test cases to have. 👍
import os | ||
|
||
sys.path.append(os.path.dirname(os.path.dirname((__file__)))) | ||
from testlib import expects |
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.
Not actually used?
sys.path.append(os.path.dirname(os.path.dirname((__file__)))) | ||
from testlib import expects | ||
|
||
# These are defined so that we can evaluate the test code. |
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.
These definitions feel like boilerplate that should be shared among tests more generally (and hence defined elsewhere -- testlib
perhaps?), but I may be missing something about the setup.
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.
It is boilerplate, and actually, some of our tests do an import instead. I should change this.
Co-authored-by: Taus <tausbn@github.com>
This can also serve for a place to add tests for
constructs like threading.Thread, mulitprocess.Process, concurrent.futures.ThreadPoolExecutor, and concurrent.futures.ProcessPoolExecutor.
Pull Request checklist
All query authors
.qhelp
. See the documentation in this repository.Internal query authors only
.ql
,.qll
, or.qhelp
files. See the documentation (internal access required).