diff_cover icon indicating copy to clipboard operation
diff_cover copied to clipboard

specify diff-range from compare_branch, then you can compare diff between tags or commit points

Open colin-lee opened this issue 3 years ago • 3 comments

specify diff-range from compare_branch, then you can compare diff between tags or commit points

colin-lee avatar Oct 24 '22 10:10 colin-lee

Perhaps the --diff-range-notation and --compare-branchoptions can be removed and replaced with a new --diff-range option? Default value origin/main...HEAD.

ptzz avatar Nov 15 '22 06:11 ptzz

@ptzz in theory that could work.

In practice id rather avoid breaking people's workflows. So we would probably want to deprecate the original two options

Bachmann1234 avatar Nov 15 '22 16:11 Bachmann1234

Looking for whether I need to specify a branch or whether I can just specify a commit, I did find this MR and it has helped me understand that, yes, I can just run diff-cover --compare-branch HEAD~1 to understand where I messed up.

Background: I am trying to figure out which of my changes in the last commit leads to a test failure. So I need to know which lines of those changed are even executed by the failing integration test.

(and for that purpose it would be nice if I could nicely get the covered lines out of diff-cover instead of the uncovered lines, but it is already very handy to compare to the previous version without having to create a branch on it.)

Anaphory avatar Feb 20 '23 14:02 Anaphory

closing due to inactivity.

Bachmann1234 avatar Jun 25 '24 22:06 Bachmann1234