-
Notifications
You must be signed in to change notification settings - Fork 646
Code coverage decorator does not work on Windows. #1847
Comments
|
No, the command runs the tests but does not show any code coverage. Re-running the command seems to have the same effect (ie. it is not toggling in a different direction).
|
From the output, we can see that the coverage was calculated successfully. |
Hi, I have the same problem with Windows 10 and go 1.11rc1.
|
|
@BenLubar But I see backward slashes in the coverage output on my Windows machines. I am using 1.9 |
go version go1.11rc1 windows/amd64 |
Update: |
Update: |
@amsokol, @BenLubar I have pushed a fix to the master branch. Can you try it out and let me know if it works for you as well? To try the fix, just follow the instructions at https://github.com/Microsoft/vscode-go/wiki/Use-the-beta-version-of-the-latest-Go-extension |
It seems to have exactly the same effect (that is, no coverage information is displayed in the editor, but it does generate coverage information in the temp folder). Here's the result of |
cc @bcmills The file produced by |
@BenLubar I've pushed another fix, can you try |
Hi @ramya-rao-a, I got the same problem with @BenLubar and I tried the beta version of Go extension. Now, the code coverage works fine just like the previous Go version! Thankyou 🙏 |
If this is a bug report, please share
This issue is reproducible with any Go package that contains tests.
I doubt these are relevant, but here is my entire
settings.json
file:Steps to Reproduce:
I suspect this is because Go's code coverage output always uses forward slashes but Visual Studio Code uses backslashes for file paths on Windows.
This is visible in the
Go: Install Current Package
command, butgo install github.com\foo\bar
works exactly as the expected command does.The text was updated successfully, but these errors were encountered: