From: Than McIntosh
Date: Tue, 5 Dec 2023 20:15:06 +0000 (-0500)
Subject: doc: add release note on coverage testing of no-test packages
X-Git-Tag: go1.22rc1~90
X-Git-Url: http://www.git.cypherpunks.su/?a=commitdiff_plain;h=c002a5d8abef3037dd5f13e0c60cf42b86b4d885;p=gostls13.git
doc: add release note on coverage testing of no-test packages
Add a small release note blurb to describe the changes in CL 495447
relating to "go test -cover" runs on packages with functions but no
tests.
For #61422.
Change-Id: Ib8163ac70b902f0d7f9f470b944e7f70711e3cf3
Reviewed-on: https://go-review.googlesource.com/c/go/+/547635
Reviewed-by: Bryan Mills
Auto-Submit: Than McIntosh
LUCI-TryBot-Result: Go LUCI
---
diff --git a/doc/go1.22.html b/doc/go1.22.html
index 05c7cc090c..64afa898af 100644
--- a/doc/go1.22.html
+++ b/doc/go1.22.html
@@ -53,6 +53,25 @@ Do not send CLs removing the interior tags from such phrases.
+
+
+`go` `test` `-cover` now prints coverage summaries for covered
+packages that do not have their own test files. Prior to Go 1.22 a
+`go` `test` `-cover` run for such a package would report
+
+
+
+ ? mymod/mypack [no test files]
+
+
+
+ and now with Go 1.22, functions in the package are treated as uncovered:
+
+
+
+ mymod/mypack coverage: 0.0% of statements
+
+
Cgo