-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
Wrap unittest method test in TestSuite #3295
Wrap unittest method test in TestSuite #3295
Conversation
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.
This is a great change, I think we should ultimately accept it, thanks!
However, could you add a test plan for this adjustment to the Python code? We don't have unit or system tests set up (yet) for Python files in our extension - something I hope to rectify in the next quarter.
A test suite that would show the behaviour without your change would be one where tests fail if the suite initialization method is not called first. Please add this to .github/test_plan.md
.
Also, please add a news
entry for your PR (remembering to thank yourself) and I will accept.
Again, thanks!
Sure thing! I'll see what I can do. |
@d3r3kk modified the test plan + added news entry; also merged the newest upstream changes. |
Thanks for finishing up @alexander-yu! I will take this up with the team tomorrow and see if we want to include it for the next release after our mid-December. |
🎆 We've merged the change, will be included in the upcoming release for Dec. |
For #3252
package-lock.json
has been regenerated by runningnpm install
(if dependencies have changed)This PR addresses something I noticed in #3252, where clicking
Run Test
for a single unittest method (when choosing unittest as the test framework) leads tosetUpClass
not being run, even though it does occur when runningRun Test
for the entire class.Looking through the test launcher, it appears that if we're running a single test method, then we actually end up running a bare
TestCase
object, whoserun
method (which is called by the unittest test runner) only callssetUp
. Wrapping theTestCase
object with aTestSuite
class ensures thatsetUpClass
is called.