-
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
unittest tests stop working or are not found by the extension over time #2376
Comments
Thanks for the report. However, to better to diagnose the issue a bit more information would be most helpful. What steps did you take to get into this state? What code were you working in? (attaching a code sample, or a link to a Github repo can help here). What other modules are being used? Version information of these as well. |
Ok, steps to reproduce are quite easy, at least in my case. Just run Run all unit tests. On status bar there is number of passed tests. In my case it is 6 after start. Aftre rerun of command, it is 12, after rerun it is 18, etc. Furthermore, in developer console I saw:
But I have unistalled anaconda recently. It almost seems that VSCode believes it is presented. Nevertheless, I tried to install Anacoda with no better result. The modules The repo code is here: But I dont believe it is related to code as I remember I saw something similar before. |
I tried to repeat on completely different machine with Windows 10 and Python 3.6.6 and I can confirm exactly same behavior for simple dummy test file, not related to previous one. See pictures: Hope it helps. |
Thanks so much! That clears things up a lot. I've been working on the test counter in the status bar recently, and I believe I have it solved. See issue #2143. This is likely a related problem caused by multiple registration of event listeners. I've rectified the issue locally and will be putting forth a PR shortly to remedy it. |
But since your issue is slightly off the topic of my fix (tests stop being reported, are they even being run?) I want to keep this one open until we show it is fixed as well. |
If tests are found, then tests are run. Just they numbers doubles every time. I didnt encounter any incorrect results in my tests when compared to tests through command line. Thanks for your hardwork. |
Just one note and I believe it is the same as mine. IMHO, this issue can be closed. |
Just being cautious! I'll be sure to add unit tests to ensure that we can run many iterations of the unittests and not lose any along the way. Seems to be a pretty decent test to have anyways 😃 |
Duplicate of #2143 |
Issue Type: Bug
The "python run test" works fine from the start. Then it seems extension loses location to tests as it is not able to find them. Only way to amend is to restart vscode. It helps just for a while, then the issue repeats.
Test framework is unittest.
I have tried to use completely new installation with the same result.
I experienced this with Python 3.6 and 3.7
This is from Develop console
Extension version: 2018.7.1
VS Code version: Code 1.25.1 (1dfc5e557209371715f655691b1235b6b26a06be, 2018-07-11T15:43:53.668Z)
OS version: Windows_NT x64 10.0.17134
System Info
flash_3d: unavailable_software
flash_stage3d: unavailable_software
flash_stage3d_baseline: unavailable_software
gpu_compositing: unavailable_software
multiple_raster_threads: disabled_off
native_gpu_memory_buffers: disabled_software
rasterization: unavailable_software
video_decode: unavailable_software
video_encode: unavailable_software
vpx_decode: unavailable_software
webgl: unavailable_off
webgl2: unavailable_off
The text was updated successfully, but these errors were encountered: