-
Notifications
You must be signed in to change notification settings - Fork 85
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
Reveal and fix a masked test #1671
Conversation
the test method started with an underscore which is why unittest wasnt discovering it modified: traits/etsconfig/tests/test_etsconfig.py
The test failed as expected -
Fixing it now. |
we are making a strong assumption here that the tests are being run using unittest modified: traits/etsconfig/tests/test_etsconfig.py
modified: traits/etsconfig/tests/test_etsconfig.py
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 a quick fix, though having the validity of the test tied to the choice of test runner isn't ideal.
Probably we should rethink the whole way that application_data
gets its default.
I have opened #1672 for this. |
* DEV: Reveal a masked test method the test method started with an underscore which is why unittest wasnt discovering it modified: traits/etsconfig/tests/test_etsconfig.py * FIX: Update the app_name and get the test passing we are making a strong assumption here that the tests are being run using unittest modified: traits/etsconfig/tests/test_etsconfig.py * CLN: Remove the now unnecessary dundername/dundermain clause modified: traits/etsconfig/tests/test_etsconfig.py (cherry picked from commit f379908)
The test name started with an underscore which is why unittest wasnt discovering it.
Once the leading underscore is removed, we noticed that the test assertion fails - because the
app_name
that the code infers by default is different.We update the assertion to pass - with the strong assumption that the tests are run using
unittest
- which traits uses for test discovery and to run the tests.Checklist
TestsUpdate API reference (docs/source/traits_api_reference
)Update User manual (docs/source/traits_user_manual
)Update type annotation hints intraits-stubs