]> Cypherpunks repositories - gostls13.git/commitdiff
net/http/httptest: add comment to Server.Client() about Server.URL
authorAlireza Ghasemi <agcombest@gmail.com>
Thu, 9 May 2024 06:07:55 +0000 (06:07 +0000)
committerGopher Robot <gobot@golang.org>
Fri, 10 May 2024 17:26:10 +0000 (17:26 +0000)
Updates #30774.

Change-Id: I9564f955b15c701bee27aa9fbf3972de8fdb55e4
GitHub-Last-Rev: 50bd6bd54ec4195ed9e09a4a2d69e386bf55b21f
GitHub-Pull-Request: golang/go#67037
Reviewed-on: https://go-review.googlesource.com/c/go/+/581777
Reviewed-by: Damien Neil <dneil@google.com>
Auto-Submit: Damien Neil <dneil@google.com>
Reviewed-by: Cherry Mui <cherryyz@google.com>
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>

src/net/http/httptest/server.go

index 5095b438ec9487d214e7e84b2ade092700b788bb..fa549231796925fc61b23d53d477280cfaafaece 100644 (file)
@@ -299,6 +299,7 @@ func (s *Server) Certificate() *x509.Certificate {
 // Client returns an HTTP client configured for making requests to the server.
 // It is configured to trust the server's TLS test certificate and will
 // close its idle connections on [Server.Close].
+// Use Server.URL as the base URL to send requests to the server.
 func (s *Server) Client() *http.Client {
        return s.client
 }