Skip to content

Commit 5f5ae8d

Browse files
authored
Merge pull request #6 from infosiftr/100-percent-stripper-coverage
Update "pkg/stripper" coverage to 100% with a smaller buffer size
2 parents 552554d + 273a377 commit 5f5ae8d

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

pkg/stripper/comments_example_test.go

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,8 @@ e: f
2121

2222
comStrip := stripper.NewCommentStripper(r)
2323

24-
io.Copy(os.Stdout, comStrip)
24+
// using CopyBuffer to force smaller Read sizes (better testing coverage that way)
25+
io.CopyBuffer(os.Stdout, comStrip, make([]byte, 32))
2526

2627
// Output:
2728
// a: b

0 commit comments

Comments
 (0)