Skip to content

Commit

Permalink
fix(diff): use arg '--strip-trailing-cr' (#949)
Browse files Browse the repository at this point in the history
In tests with diff, ignores trailing carriage returns (so tests pass on windows)
  • Loading branch information
umarcor authored Nov 16, 2021
1 parent 442031e commit 62a72cd
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion cobra/cmd/golden_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ func compareFiles(pathA, pathB string) error {
// Don't execute diff if it can't be found.
return nil
}
diffCmd := exec.Command(diffPath, "-u", pathA, pathB)
diffCmd := exec.Command(diffPath, "-u", "--strip-trailing-cr", pathA, pathB)
diffCmd.Stdout = output
diffCmd.Stderr = output

Expand Down

0 comments on commit 62a72cd

Please sign in to comment.