Go to next uncovered line
Is your feature request related to a problem? Please describe.
When reviewing coverage in a file and finishing writing tests for a block, it would be useful to be able to quickly go to the next uncovered section.
Describe the solution you'd like
Add two new commands - one to go to the next branch-uncovered line, and one to go to the next fully uncovered line.
Describe alternatives you've considered
Currently I open lcov's generated HTML report alongside vscode and use the shortcuts there
@Gerrit0 Thanks for the feature suggestion! This seems like a nice addition to the extension, a couple questions for yeah.
-
Do you see the commands being purely keyboard shortcut based or could there be GUI elements of some sort? (Maybe inline buttons kinda like git lense)
-
Should the commands take the current cursor position into account when figuring out the next uncovered line / next uncovered branch? If it doesn't, then I guess the command is just iterating through the coverage lines for the current active editor file 🤔.
Some code areas that would be important for when we work on this:
- Adding new commands to the extension
- https://github.com/ryanluker/vscode-coverage-gutters/blob/master/src/extension.ts#L39
- Adding new functionality to the coverage service to extract the next line or branch within the a specific file (and optionally the line number).
- Currently, we only interact with the coverage info / cache once when we want to render something to the IDE.
- https://github.com/ryanluker/vscode-coverage-gutters/blob/master/src/coverage-system/coverageservice.ts#L126
- I think the buttons would be a nice touch -- I'm unlikely to use them, but if they are there it would make the commands more discoverable for other users; which is important!
- Cursor position absolutely should be taken into account! I'm imagining this working like VSCode's prev/next error shortcut.
I think the buttons would be a nice touch -- I'm unlikely to use them, but if they are there it would make the commands more discoverable for other users; which is important!
- Cursor position absolutely should be taken into account! I'm imagining this working like VSCode's prev/next error shortcut.
Excellent, thanks for the other infos, and hopefully we will work on this shortly in the future 👍🏻.